Twenty-five people have died and dozens sent to hospital after a fire tore through a building in northern China's Shanxi province on Thursday, state media said.

The fire started at a four-floor building belonging to the Yongju coal company in Shanxi province's Luliang city at around 6:50 am (2250 GMT on Wednesday), state media said, citing local authorities.

Twenty-five people have been confirmed dead, state broadcaster CCTV reported.

Earlier, CCTV said that 63 people had been evacuated, 51 of whom were hospitalised.

State media did not say if any of those taken to hospital had died.

"Rescue work is still in progress and the cause of the fire is under investigation," it said.

A later update said the fire had "now been brought under control".

Video footage posted on social media site Weibo showed bright flames and thick black smoke billowing from the building, while dozens of people stood in the parking lot watching.

The building shown in the video matched images of the company's headquarters posted on its website.

Emergency response personnel could be seen in the footage racing to put on protective gear outside a firetruck parked at the building's entrance.

Industrial accidents are common in China due to lax safety standards and poor enforcement.

In July, 11 people died after the roof of a school gym collapsed in the country's northeast.

The month before, an explosion at a barbecue restaurant in northwestern China left 31 dead and prompted official pledges of a nationwide campaign to promote workplace safety.

In April, a hospital fire in Beijing killed 29 people and forced desperate survivors to jump out of windows to escape.

One of the worst such accidents took place in 2015 in Tianjin, where a gigantic explosion at a chemical warehouse killed at least 165 people.