The London Fire Brigade (LFB) has been condemned for "serious shortcomings" and systemic failures in its response to the Grenfell Tower fire, in a report into the 2017 blaze.
Fewer people would have died in the fire if the LFB had taken certain actions earlier, the report by inquiry chairman Sir Martin Moore-Bick said.
He also said some evidence given by the LFB at the inquiry was "insensitive".
The BBC has seen sections of the report ahead of Wednesday's publication.
The 1000-page document follows the first phase of the inquiry, which looked at what happened on the night that 72 people died in the tower block fire on 14 June 2017.
The council, the tower's tenant management organisation, the police and the fire service were all quizzed during the inquiry's first phase.
Sir Martin's report praised the courage of firefighters on the night.
But it found many "institutional" failures that meant the LFB's planning and preparation for the incident was "gravely inadequate".
For example, Sir Martin said control room staff who fielded 999 calls "undoubtedly saved lives" but "a close examination" of operations revealed "shortcomings in practice, policy and training".
"Supervisors were under the most enormous pressure, but the LFB had not provided its senior control room staff with appropriate training on how to manage a large-scale incident with a large number of FSG [Fire Survival Guidance] calls," he said.
"Mistakes made in responding to the Lakanal House fire were repeated," he added - referring to a fire in Camberwell, south London, in 2009, which killed three women and three children.
Sir Martin also criticised the LFB for its "stay put" strategy, where firefighters and 999 operators told residents to stay in their flats for nearly two hours after the blaze broke out.
The strategy was rescinded at 02:47 BST, the report said. Sir Martin wrote: "That decision could and should have been made between 01:30 and 01:50 and would be likely to have resulted in fewer fatalities."
Firefighters who attended the fire did not have training on how best to combat a cladding fire, the report added.
Four experienced members of the first crews to have fought the blaze had not received any training on the risks posed by exterior cladding or the techniques to be deployed in fighting fires involving cladding, the report found.
Sir Martin said the "principal" reason the fire spread so quickly "up, down and around the building was the presence of the aluminium composite material (ACM) rainscreen panels with polyethylene cores, which acted as a source of fuel".
The report also said evidence given by the LFB's commissioner, Dany Cotton, suggested lessons from the fire might be missed.
Sir Martin wrote: "Quite apart from its remarkable insensitivity to the families of the deceased and to those who escaped from their burning homes with their lives, the Commissioner's evidence that she would not change anything about the response of the LFB on the night, even with the benefit of hindsight, only serves to demonstrate that the LFB is an institution at risk of not learning the lessons of the Grenfell Tower fire."
A spokesperson for the LFB said it would be "inappropriate" to comment on the report's findings before they were officially released on Wednesday.
Speaking on Monday, Sir Martin said the report was long and detailed.
He stressed that readers of the report "should understand as clearly as possible the terrifying conditions faced by those who were in the building, at the time".
The cause of the fire was found by the report to be "an electrical fault in the large fridge freezer in the kitchen" in a fourth-floor flat.
"It occurred without any fault on the part of the tenant... and I am pleased to clear him of any blame, given that some people have unfairly accused him of having some responsibility for what happened," Sir Martin said.