A motorist, who ignored warning lights and drove around level crossing barrier arms at a known blackspot, was seconds away from being hit by a train, a driver who filmed the incident says.
The witness, who wanted to be known only as Chris, said he had seen numerous occasions where motorists navigated the safety barriers to cross the tracks.
"They put raised islands in to stop people weaving around the boom gates, but as you see in the video, they just drive over them."
He caught the incident at the St Jude St crossing in January after earlier fixing a camera to his car to film poor driving.
KiwiRail has confirmed the crossing was a known blackspot, where train drivers had reported a high number of near misses.
After the vehicle crossed the tracks, a train flew by just seconds later, Chris said.
"I couldn't believe it, it was quite a shock to see someone do that."
The track was on a bend and motorists could not see trains approaching, he said.
The footage has emerged at the start of Rail Safety Week, which was launched at Wellington Railway Station today.
In Auckland alone, in the past six months, KiwiRail has repaired 50 barrier arms that vehicles have driven through in a bid to beat the train.
This year, five people have died in four crashes and there have been more than 70 near-misses reported.
Today, a simulator was unveiled at the station that gave a dramatic demonstration of seeing through a train driver's eyes what happens when vehicles, cyclists and pedestrians put their lives at risk by crossing in front of trains.
KiwiRail external relations general manager Deb Hume said it was economically impractical to put barriers at all crossings.
"It's couple of hundred thousand dollars to put in lights and bells and it's another $90,000 on top of that ... to put in barrier arms."
But the company was assessing the country's crossings all the time, she said.
National road policing manager Superintendent Carey Griffiths said in an "ideal world" there would be barriers at all crossings.
"We're all trying to prevent that senseless waste of life."
About 20 pupils from Upper Hutt's Plateau Primary School were at the unveiling had a turn on the simulator.
Braydn Howchow, 9, said it was scary when a child ran across the track in front of his train.
"And I nearly crashed into a tree."
But he learned some pretty good lessons about what to do when he was near train tracks.
"Walk across the crossing and not over the track."
- 2014 year to date: 15 collisions with five fatalities in four different crashes;
- 2013: 18 collisions with three fatalities;
- Trespassers: 2014 - five collisions, one fatal, four injuries; 65 near collisions.
* Crashes over the past 10 years
- 12 per cent at crossings with barriers, lights and bells;
- 37 per cent at crossings with lights and bells;
- 51 per cent at crossings with stop or give way signs.
* Reported near collisions
- 2009-2013: 573
- 2014 year to date: 71