The Associated Press reported that the authorities were helping injured runners leave the scene and bloody spectators were being carried to a medical tent that was being used for runners.
The A.P. said that a loud explosion was heard on the north side of Boylston Street, near a photo bridge that marks the finish line. Another explosion was heard several seconds later.
Local television showed ambulances at the scene. Pictures posted online showed several injured runners being attended to and smoke around the finish line.
The headquarters for the organizers of the marathon, one of the world’s oldest, was reportedly locked down while authorities investigate. Reporters inside the Copley Plaza Hotel, where the media center is and where many elite athletes are staying, were unable to leave.
The explosions went off more than four hours after the start of the men’s race, which meant that there were still several thousand runners yet to finish the race.
Big city authorities are typically on the highest levels of alert for events like a marathon, said Anthony Roman, a security expert.
“It is quite the counterterrorism effort,” said Mr. Roman, who runs Roman & Associates, a New York firm.
For major events in New York and other large cities, Mr. Roman said the police would typically weld manhole covers shut, while also examining the entire route just before the race. They will also place snipers on rooftops, with helicopters overhead. Analytic cameras in the city will be focusing on the race, he said.
“They have all the analytic cameras in the city focusing on the race with their advanced software network, reading license plates,” Roman said.
The Boston Marathon is one of track’s most storied events, established in 1897 and one of the six World Marathon Majors. The event typically attracts an estimated 500,000 spectators and requires certain qualifying times for runners to compete. The course winds throughout downtown Boston as well as several outlying cities, including Ashland, Framingham, Natick, Wellesley and Newton.
Unlike many sporting events that take place in closed arenas, marathons are known and heralded for their sprawl, allowing throngs of spectators to line the 26.2-mile course.
Within minutes of the explosions on Monday, social media and cable networks projected the images of gray smoke on Boylston Street in Boston, emergency crews on the scene and an unknown number of persons injured.