At least seven people have been killed in Jakarta after a commuter train crashed into a truck carrying gas and burst into flames.

More than 70 people were injured in the collision at a crossing in Bintaro Permai, southern Jakarta, hospital officials said.

"The engineer attempted to brake, but then a fuel truck ran onto the railroad tracks and the brakes could not stop it from hitting the truck. It exploded and bounced off," one passenger said. "It happened so fast!"

Images from the scene showed flames shooting from parts of the train. Two of the train's eight carriages, including a women-only car, were derailed and could be seen lying on one side off the tracks.

About 500 passengers were aboard the train, which was heading towards central Jakarta when it slammed into the truck belonging to state oil company Pertamina.

The tanker was carrying some 24,000 liters (6,340 gallons) of gasoline.

Among the victims were the train engineer and a technician, Jakarta police spokesman Col. Rikwanto said.

"My position was near the door, but I could not move because I was ... trampled by other passengers," said one of the passengers who was aboard the women-only car.

"We managed to escape after people from outside broke the windows. I saw many victims with burns on their legs, hands and stomachs," she said.

Firefighters rushed to the scene and were attempting to reach victims stuck inside the wreckage.

Authorities said they were investigating the cause of the incident. The train company, PT KAI, said all train signals were working at the time of the crash.