ABUJA, Nigeria — At least 35 people were killed on Monday and hundreds were injured when a gas tanker exploded in the northern Nigerian state of Nasarawa, an emergency services official said.

The accident happened as the truck was unloading at a gas station along the Lafia-Makurdi road linking the capital city, Abuja, with northern and southern Nigeria, said Usman Ahmed, acting director of the State Emergency Management Agency.

The agency was investigating the explosion, he said.

“We have confirmed 35 dead and over a hundred injured,” Mr. Ahmed said. “Most of those that died rushed to the accident spot to see what was happening.”

In June, at least nine people were killed in Nigeria’s commercial capital, Lagos, when a gasoline tanker caught fire and burned 53 other vehicles.