The inspection of the site on Filmer Road in Fulham was carried out during a clampdown on poor safety conditions on basement projects in November 2013.
The HSE found workers were being exposed to extremely dangerous conditions on the site, being made to work in and around deep excavations of up to four metres in depth that were not properly supported.
Westminster Magistrates court heard that basement excavation under existing buildings poses significant dangers and safe systems of work must be in place at all times.
These include the appointment of a temporary works engineer, clear and competent site management and adequate shoring and propping of all excavations.
Darma Limited failed in its duty to provide any of these measures – putting workers at risk of death.
The company were fined £13,400 and ordered to pay £4,719 in costs after admitting a breach of the CDM regulations.
After the hearing, HSE Inspector Dominic Long said: “Conditions on this site were appalling with deep unsupported excavations throughout the basement.
“This not only put the large number of operatives in the basement at risk of death but could also have led to the collapse of the building itself.
“Darma Limited showed scant regard for the safety of the workers they were responsible for, it was extremely fortunate no-one was seriously injured or killed.”