Send this page to someone via email

Google, which is owned by Alphabet Inc, and its YouTube video service will pay $170 million to settle allegations that it broke federal law by collecting personal information about children, the Federal Trade Commission said on Wednesday.

The settlement with the FTC and the New York attorney general’s office, which will receive $34 million, is the largest since a law banning collecting information about children under age 13 came into effect in 1998. The law was revised in 2013 to include “cookies,” used to track a person’s internet viewing habits.

WATCH: A Montreal man is one of eight people launching a class action lawsuit against YouTube in the U.S.

1:57 A Montreal man is one of eight people launching a class action lawsuit against YouTube in the U.S. A Montreal man is one of eight people launching a class action lawsuit against YouTube in the U.S.

YouTube had been accused of tracking viewers of children’s channels using cookies without parental consent and using those cookies to deliver million of dollars in targeted advertisements to those viewers. Google declined comment when this settlement leaked last week.

Story continues below advertisement

YouTube allows companies to create channels, which include advertisements that create revenue for both the company and YouTube.

In its complaint, the government said that YouTube touted its popularity with children in marketing itself to companies like Mattel and Hasbro. It told Mattel that “YouTube is today’s leader in reaching children age 6-11 against top TV channels,” according to the complaint.

READ MORE: YouTube puts original series in front of paywall as streaming competition heats up

“YouTube touted its popularity with children to prospective corporate clients,” FTC Chairman Joe Simons said in a statement. “Yet when it came to complying with (federal law banning collecting data on children), the company refused to acknowledge that portions of its platform were clearly directed to kids.”

New York Attorney General Letitia James said the companies “abused their power.”

“Google and YouTube knowingly and illegally monitored, tracked, and served targeted ads to young children just to keep advertising dollars rolling in,” said New York Attorney General Letitia James.

In addition to the monetary fine, the proposed settlement requires the company to refrain from violating the law in the future and to notify channel owners about their obligations to get consent from parents before collecting information on children.