Four fire engines and around 25 firefighters were called to a flat fire on Fairfield Road in Croydon.
Part of a five-roomed flat on the first floor of the building was damaged by fire. One man and a woman were treated on scene by London Ambulance Service crews.
Station Officer Luke Sedge, who was at the scene, said: “As we arrived, we could see flames coming out of the first floor window and around 40 people were out of the building.
“Crews worked quickly to bring the fire under control and prevent the fire from causing further damage.”
The Brigade was called at 0450 and the fire was under control by 0552. Fire crews from Croydon, Woodside and Norbury fire stations attended the scene.
The cause of the fire is under investigation.