• The toddler was playing in the front yard of his home
  • His grandfather noticed a 6-foot-long King Cobra slithering towards them
  • The one-minute video has since gone viral with more than one million views

A hair-raising video of a deadly snake attempting to follow a toddler inside a home in Vietnam has gone viral on social media.

In the video shared on YouTube on Friday, the toddler can be seen playing in the front yard of the home, with his grandfather standing beside him. Suddenly, the grandfather notices a 6-foot-long King Cobra slithering towards them and immediately alerts the boy’s father, who is sitting a few feet away.

The father then rushes towards the child, picks him up and all of them run back into the home. The reptile follows them in a flash. The child’s grandfather, however, manages to shut the door at the right moment, leaving the snake outside.

Unable to enter the home, the reptile slithers all around the yard, moving through items kept on the floor. It eventually moves out of the yard.

The video was uploaded on YouTube by ViralHog with the statement of the child's mother as the caption, "There was a 2-meter king cobra slithering into my house when my son was playing his toy in the front yard. The man who was standing is his grandfather. As the grandfather has just recovered from a stroke, he couldn't react quickly; he saw the snake slithering and he shouted out loud in order to call my husband to rescue the kid. Luckily, everyone is fine!"

The one-minute video has since gone viral with more than one million views. Several people took to the comments section and said they were surprised to see the snake being that fast and agile.

"Wow didn't expect it to be that fast and agile based on the old man's reaction when he initially spotted it. Good thing the younger guy was there for both him and the baby!" one person commented.

"Look at the speed man... Today I strongly believe that one should never underestimate snakes. They can reach u at a whopping speed n u won't get a sec more to think about what to do not become a hero... firstly try to escape n leave the material things n save firstly urself....then in that way, u can borrow some time to think," wrote another user.

A Krabi Pitakpracha Foundation snake handler holds the four-metre (13 feet) king cobra he pulled from a sewer in southern Thailand Representational image of a king cobra Photo: KRABI PITAKPRACHA FOUNDATION / Handout