Five people have been killed and 18 injured as a car struck a crowd of children outside a school in north-eastern China, state media said.

The driver was taken into custody after the collision in the coastal city of Huludao in Liaoning province, state broadcaster CCTV said.

The cause is under investigation, according to the reports.

Security camera footage showed a line of children crossing the street in front of the school when a car approaches, then changes lanes and swerves into a crowd of the children. At least half a dozen students appear to be hit.

Wang Mingkuan, a cook at a nearby noodle restaurant, said he was making meals when the crash occurred.

“I ran out and saw about a dozen children lying on the ground, some of them bleeding, all about seven or eight years old. Two or three showed no signs of life,” Mr Wang said.

He added that ambulances and police cars rushed to the scene and officers blocked off the area and prevented people from filming. He said rumours about the driver included that he was drunk, fleeing police or deliberately targeted the children.

While it was not clear if the crash was a deliberate attack, China has recently seen a number of such incidents.

Last month, a knife-wielding man drove a vehicle into a crowd of pedestrians in the eastern city of Ningbo, killing two people and wounding 16.

In September, 11 people were killed and 44 injured after a man drove a car deliberately into people at a plaza in the central province of Hunan, before jumping out and attacking victims with a dagger and shovel.

The most common motivations are identified as mental illness, alienation from society or a desire to settle scores.

Other deadly attacks have occurred at schools, including several in 2010 in which nearly 20 children were killed, prompting a response from government officials and leading many schools to beef up security.

In June this year, a man used a kitchen knife to attack three boys and a mother near a school in Shanghai, killing two of the children.

Last year, police said a man set off an explosion at the front gate of a nursery in eastern China, which struck as relatives gathered to pick up their children at the end of the day, killing eight people.