Baltimore Mayor Stephanie Rawlings-Blake said five of the six had been taken in custody.
"The findings of our comprehensive, thorough and independent investigation, coupled with the medical examiner\’s determination that Mr. Gray\’s death was a homicide … have led us to believe that we have probable cause to file criminal charges," Mosby said.
Mosby said Gray "suffered a severe and critical neck injury as a result of being handcuffed, shackled by his feet and unrestrained" inside a moving police van.
En route to the Western District police station, the police van stopped at least three times, including once to pick up a suspect in an unrelated case.
Cheers broke out when Mosby unveiled the charges on the steps of Baltimore\’s war memorial, across the street from city hall — a focal point of protests demanding justice over Gray\’s death.
Baltimore\’s police union condemned what it called "an egregious rush to judgement" as it defended the officers and expressed confidence they would be vindicated.
"We believe that these officers will be vindicated as they have done nothing wrong," said Michael Davey, a lawyer working for the city\’s Fraternal Order of Police.
"I have never seen such a hurried rush to file criminal charges," he added, suggesting that prosecutors had rushed their investigation because of the pressure from demonstrations.
Many in this East Coast port city of 620,000, about an hour\’s drive north of Washington, had expected Mosby to say that the case was still under investigation, one day after Police Commissioner Anthony Batts submitted his findings in the case.
"I didn\’t know that a decision would be coming today," said Congressman Elijah Cummings, whose district includes much of Baltimore.
Cars honked their horns, and youths chanted "Justice for Freddie Gray" as they lifted their fists into the air in a gesture of victory.
Baltimore is still under a state of emergency, with the National Guard alongside police in riot gear on the streets, and an overnight curfew in place.
Gray, who had a record of non-violent drug offenses, died April 19 from spinal injuries sustained when he was arrested a week earlier in a west Baltimore public housing estate.
Facing the most serious charges of second-degree murder is Officer Caesar Goodson, the driver of the van that transported Gray to a police station.
Goodson, 45, was also charged with involuntary manslaughter, second-degree assault, vehicular manslaughter and misconduct.
Goodson got out of the van to check on Gray\’s condition, Mosby said, but "at no point did he seek nor did he render any medical assistance."
Three other officers were charged with involuntary manslaughter, second-degree assault and misconduct, and two more charged with second-degree assault and misconduct.
One officer was also charged with false imprisonment.
All six officers have been suspended with pay since Gray\’s death.
Mosby — an African-American woman who is the daughter, granddaughter and niece of police officers — said Gray had been "illegally arrested" as "no crime had been committed."
She urged protesters to keep the peace in the wake of the charges, and reiterated that the investigation was ongoing.
In an open letter, Baltimore\’s police union called for a "special independent prosecutor" to take over the case from Mosby, who at 34 is America\’s youngest big-city chief prosecutor.
It cited Mosby\’s relationships with Gray\’s family lawyer, who contributed $5,000 to her election campaign, and her husband, a city council member who represents the poverty-stricken section of Baltimore where Gray lived and died.
"We believe the actions taken today by the state\’s attorney are an egregious rush to judgment and grave concerns about the fairness in prosecution of our officers," said Michael Davey, the union\’s lawyer.
Baltimore police lieutenant Kenneth Butler added: "We are extremely frustrated and shocked by the circumstances that have transpired today."
Gray has become the latest face of an intense national debate over whether American police are too quick to use violence against unarmed black males.
In the best-known case, a white police officer fatally shot unarmed teenager Michael Brown in Ferguson, Missouri — prompting riots in the St. Louis suburb — but was not indicted by a grand jury.
In December, a grand jury similarly did not indict a New York police officer over the chokehold death of Eric Garner.
In North Charleston, South Carolina, a police officer stands accused of murder after he was captured on video fatally shooting Walter Scott during a traffic stop on April 4.
And in Oklahoma, a reserve deputy sheriff has pleaded not guilty of manslaughter after he fatally shot Eric Harris during a sting operation.
At the White House in Washington, President Barack Obama said it was "absolutely vital" for the truth to come out.
"What I think the people of Baltimore want more than anything else is the truth. That\’s what people around the country expect," he said.