U.S. District Judge Catherine Perry issued her ruling after a public hearing of several hours in St. Louis, where more than two dozen people spoke, and many others had submitted written comments. Perry said the settlement is a "reasonable resolution" that avoids years of an extensive court battle.
"I think it's in everyone's best interest, and I think it's in the interest of justice," she said.
The settlement calls for the hiring of a monitor; diversity training for police; the purchase of software and hiring of staff to analyze records on arrests, use of force and other police matters; and the outfitting of all officers and jail workers with body cameras.
Mayor James Knowles III told Perry that the city believes the agreement "is an important step in bringing this community together and moving us forward."
Ferguson has been under scrutiny since Brown, who was black and unarmed, was fatally shot by white Ferguson police officer Darren Wilson in 2014, and Brown's death was a catalyst in the national Black Lives Matter movement. A grand jury and the Justice Department cleared Wilson, who resigned from the police force in November 2014, but the shooting led to a Justice Department investigation.
That inquiry found alarming patterns of racial bias in policing and a municipal court system that generated revenue largely on the backs of poor and minority residents. The Justice Department's critical report in March 2015 prompted the resignations of Ferguson's city manager, police chief and municipal judge. All three were white men who have since been replaced by black men.
Ferguson leaders and Justice Department officials spent months negotiating the settlement. But in February, after a series of public hearings, the City Council rejected it, mostly over concerns the cost could bankrupt the town. The Justice Department sued the next day.
In March, after receiving some assurance that the cost wouldn't be as high as feared, the City Council approved the deal, expected to cost about $2.3 million over three years.
This story originally appeared on NBCNews.com.