The dead include three children – 5, 7 and 10 years old – and a 17-year-old teenager who tried to escape by jumping from a window, they said.
The apartment was occupied by a family believed to have Comoran origins, the regional prefect Hugues Moutouh said, referring to the southern African island nation.
Ten people were inside when the fire broke out.
Rescuers were alerted at around 2:30 am (0030 GMT) to the blaze on the seventh floor of the building in the low-income neighbourhood of Les Moulins, known for being a drug-dealing hub, in the west of the city.
In spite of the substantial resources deployed, “unfortunately seven people died during this fire”, firefighters said.
Interior Minister Gerald Darmanin said on social media that the quick arrival of firefighters “probably prevented more deaths”.
Nice prosecutor Damien Martinelli said investigators were looking into a “criminal” cause for the fire.
“In light of the initial evidence, I have opened an investigation into acts of arson leading to death,” he told reporters at the scene.
The authorities said the blaze probably broke out on the building’s second floor and spread to higher floors.
Rescuers said that three people were taken to hospital, one of them with life-threatening injuries.
They said firefighters were confronted by a “raging apartment fire” on the seventh floor of the building. They carried out three aerial ladder rescues and evacuated dozens.
In total, 25 fire engines and 72 firefighters tackled the fire.
Twenty people were evacuated to a temporary shelter, with Nice Mayor Christian Estrosi saying a crisis unit to help anyone affected by the fire.