I don't know what this guy was thanking, but he should be thanking the Lord he's still alive today.

A video has gone viral from Australia showing what easily could have been a nasty caught-on-camera death.

Luckily for this man, God didn't want him to lose his life on this day. It looks like he's waiting for a train to pass, and once it passes, he makes a run for it trying to cross the tracks. Surely he knew the other train was coming and thought he could beat it... Or he had an unfulfilled death wish.

The security cameras captures a true miracle, where the train misses the guy by a mere few inches.

Below are two different angles, perfectly captivating what should have been something far, far worse.

Check this out!