A resident said the fire was 'started by a group of young teenagers' in a stairwell in Magdalene Drive at about 11pm on Friday causing black smoke to billow through the property.
Pictures of the scene show the fire caused major damage to the interior.
"The fire spread within the stairwell filling with black smoke.
"Higher flats were trapped due to the travelling thick black smoke which the fire rescue team evaluated as ‘toxic'."
A Police Scotland spokesperson said: "Officers attended a report of a fire in a common close in Magdalene drive, Edinburgh.
"The fire was extinguished by the Scottish Fire and Rescue Service and two adults and four children were treated for the effects of smoke inhalation.
"The fire is being treated as wilful and enquiries are ongoing."