NICE - A Tunisian-born man zigzagged a truck through a crowd celebrating Bastille Day in the French city of Nice, killing at least 84 and injuring dozens of children in what President Francois Hollande on Friday called a “terrorist” attack.

One witness said a motorcyclist tried to stop the rampage by drawing level with the truck and attempting to open the door of its cab before he fell and ended up under its wheels.

Two children were confirmed among the dead and another 50 were being treated in hospital after the attack that left bodies strewn over the palm-lined Promenade des Anglais in the French Riviera resort.

Some of the dead, covered with sheets, remained on the promenade in the bright sun on Friday.

Two US citizens and a Ukrainian were among those killed, their countries said.

Witnesses said the white truck drove at speed into a crowd over a distance of two kilometres after they had been watching a fireworks display on France’s national day. City authorities said Friday that some 30,000 people had watched the display.

Details meanwhile began to emerge about the driver, identified as 31-year-old Mohamed Lahouaiej-Bouhlel.

Neighbours described him as a loner who never responded to their greetings.

Witnesses said he had also fired at police before officers shot him dead.

Hollande declared three days of mourning after the assault, as shellshocked France found itself again mourning its dead after attacks on Charlie Hebdo magazine in January 2015 and the November 2015 massacre in Paris.

“France was struck on its national day... the symbol of freedom,” said Hollande in a sombre televised address in the early hours Friday.

The attack was of an “undeniable terrorist nature”, he said.

Around 50 children were being treated at a paediatric hospital close to the scene of the attack. Some were “hanging between life and death”, a hospital official said.

The State Department said two American citizens were among the dead. A Texas-based newspaper, the Austin American-Statesman, named the victims as 51-year-old Sean Copeland and his 11-year-old son Brodie.

A Ukrainian citizen was also killed, the country’s foreign minister said on Twitter, without giving more details.

A German freelance journalist who witnessed the attack said he saw a man on a motorbike chase the truck.

“The motorcyclist attempted to overtake the truck and even tried to open the driver’s door, but he fell and ended up under the wheels of the truck,” Richard Gutjahr, 42, told AFP on Friday.

“Then the driver stepped on the accelerator and the truck sped up, accelerated and drove in a zig-zag course into the crowd.”

The condition of the motorcyclist was unknown.

In a Facebook video, witness Tarubi Wahid Mosta recounted the horror on the promenade.

“I almost stepped on a corpse, it was horrible. It looked like a battlefield,” he said.

“All these bodies and their families ... they spent hours on the ground holding the cold hands of bodies dismembered by the truck. You can’t even speak to them or comfort them,” he said.

AFP reporter Robert Holloway witnessed the white truck driving at speed into the crowd, causing “absolute chaos”.

“It was hurtling towards us and we had just enough time to yell at each other ‘get out of the way!’,” he said.

“We threw ourselves to the right where there were parked cars.

“The truck went by in a shower of debris, of broken glass and plastic. It was horrific.”

Interior ministry spokesman Pierre-Henry Brandet said 84 people were killed and scores injured in the carnage, including 18 who were in “critical condition”.

Another witness identified only as Nader told BFM television he saw the driver pull out a gun and start shooting at police.

“They killed him and his head was out the window.”

The truck, which a police source said had been rented in the region “a few days ago”, remained Friday where it had been halted, its front badly damaged and riddled with bullet holes and its tyres burst.

A source close to the investigation said an “inactive” grenade was found inside the truck, as well as “several fake rifles”.

The suspect’s neighbours said he was a quiet loner, with one family adding he never responded to their greetings in the building.

One neighbour, however, said she was wary of the “good-looking man who kept giving my two daughters the eye.”

One family lost their eight-month-old baby boy in the chaos but were reunited with him after they posted a desperate plea on Facebook.

World leaders rushed to condemn the bloodshed, with US President Barack Obama blasting “what appears to be a horrific terrorist attack”.

The attack was the third major strike against France in less than 18 months.

It comes eight months after Islamic State gunmen and suicide bombers attacked bars, restaurants, a concert hall and the national stadium in Paris, killing 130 people.

Hollande announced he would extend France’s state of emergency for three months in the wake of this latest attack and “step up” the government’s action against Islamic State targets in Syria and Iraq.

“We will continue striking those who attack us on our own soil,” he said.

IS has repeatedly singled out France as a prime target for its military action against the group in Iraq and Syria, and hundreds of jihadists have left France to fight in its ranks.