A man who ignored a red warning light at a rail crossing in the U.K. was inches from being hit by a high-speed train, on-board camera footage shows.

The London to Glasgow train, which can hit speeds up to 200 km/h according to National Rail, was forced to come to an emergency stop after the near miss on January 18.

Network Rail shared the video to warn of the dangers of ignoring rail crossing signals and to highlight how the pedestrian behaviour could have been fatal.

“The difference of just a few seconds could have led to tragedy for this man and I can’t downplay the danger he was in,” Lucy Jordan, Network Rail’s North West head of safety said in a statement. “I can’t downplay the danger he was in.”

You can see the close call in the video at the top of this article.