Jeffrey Williams was arrested Saturday night and charged with two counts of first-degree assault, one count of firing a weapon from a vehicle and three counts of armed criminal action, said St. Louis County Prosecuting Attorney Robert McCulloch. Williams was being held on $300,000 cash bond.
The two officers were injured early Thursday during heated protests outside the the police department after the resignation of the city's police chief, Tom Jackson, who stepped down in the wake of a Justice Department report that documented widespread racial bias in the city, biases that have gained national attention since the August police shooting of unarmed black teen Michael Brown.
Both officers are recovering, said St. Louis County Chief of Police Jon Belmar.
Williams, 20, fired the shots from a car moving through the area, McCulloch said. It's unclear whether he meant to shoot the police officers, said McCulloch, since Williams told investigators he was involved in some sort of dispute prior to the shooting.
McCulloch said a handgun recovered from Williams matched shell casings found from the scene of the shooting.
It appears Williams was the only person who fired any shots, McCulloch said, but there may be other people who were "participants." The investigation is ongoing.
Attorney General Eric Holder released a written statement on the arrest today, saying it "sends a clear message that acts of violence against our law enforcement personnel will never be tolerated."
A statement on behalf of the Fraternal Order of Police in St. Louis said, "We are relieved for our brother officers, their families and the people of Ferguson that this dangerous gunman is off the street and behind bars where he belongs."
The city of Ferguson issued a statement expressing gratitude to the "many citizens who provided assistance" leading up to the arrest. As a result of today's announcement," the statement said, "the city will continue its efforts, with the help of our residents and businesses, to embrace the healing which is needed to move forward."
The National Fraternal Order of Police has set up a website for people to help the Shield of Hope, a charity dedicated to the welfare of law enforcement officers in the St. Louis metropolitan area.
Get real-time updates as this story unfolds. To start, just "star" this story in ABC News' phone app. Download ABC News for iPhone here or ABC News for Android here. To be notified about our live weekend digital reports, tap here.