Image copyright Reuters

A loud boom and huge flames sent panicked San Franciscans running into the street following a gas explosion on Wednesday afternoon.

Street workers were installing fibre-optic cables on Geary Boulevard when they struck a gas line, sparking huge flames.

Five nearby buildings were set ablaze, including the Hong Kong Lounge II restaurant.

Fire-fighters spent several hours battling the flames.

Image copyright AFP/Getty

Image copyright AFP/Getty

All eight of the fibre-optic workers were accounted for and there were no injuries.

Mayor of San Francisco, London Breed, said: "The good news is that no one was injured or hurt."

Image copyright Reuters

The fire took around two and a half hours for fire crews and gas providers PG&E to extinguish.

"It's pretty dramatic I will say, but we have a good handle on it," San Francisco Fire Chief Joanne Hayes-White told reporters at the scene.

Image copyright Reuters

Spokesman for PG&E Blair Jones said workers had to "go slow" in order to prevent shutting off gas to thousands more customers.

Around 300 customers were cut off by Wednesday evening and 2,500 left without electricity.

Image copyright AFP/Getty

All pictures copyright.