The transformer explosion occurred while Eversource workers were performing routine maintenance in an underground electrical vault, fire officials said. The workers suffered injuries, but able to get out of the vault under their own power.
Witnesses described hearing a loud boom and seeing smoke and fire. One woman said she heard a worker scream.
Eversource confirmed two workers were sent to the hospital in the incident, which fire officials said would be investigated by the Occupational Safety and Health Administration (OSHA) as an industrial incident.
The explosion at Bowdoin Street near Cambridge Street was reported just before 6 p.m., Boston fire officials said. The two injured workers were taken to Massachusetts General Hospital.
Fire crews worked with Eversource to cut the power and put out a fire associated with the explosion.

