The parents of a four-year-old boy describe the moment they had to save their son from a python attack.

A hero father has described the terrifying moment his four-year-old son was attacked by 15-foot scrub python in the family’s backyard.

Evan Thompson was hosting a house-warming party at his new home in Airlie Beach on Thursday when he heard his son Clifford screaming near the pool.

When he ran to investigate, he found a massive snake had latched onto Clifford’s leg and was dragging him off their outdoor boardwalk.

“He was hanging on to the side-rail post for his life,” Mr Thompson told The Courier Mail.

“He’s hanging on the rail and it’s just dragging him, ripping his leg open and that’s when I knew I just had to act,” he said.

Mr Thompson said his first instinct was to punch the snake in the head. But when it let go, it just curled up again and struck Clifford a second time.

Mr Thompson then grabbed hold of the snake’s head and pulled open its jaw until it popped off Clifford’s thigh.

The boy was then able to ran away as Mr Thompson killed the snake with a sledgehammer.

“If I wasn’t there at the time, this snake could have killed him. It could have killed my kid easily,” he said.

“I’ve never seen a snake that aggressive. The fact he just kept coming back is something I haven’t experienced before,” he told 7 News.

Mr Thompson said the snake was about 4.5 metres long – one of the biggest he’d ever seen.

After tying a tourniquet around Clifford’s leg and dressing the wounds, he then took his son to Prosperpine Hospital for treatment.

The four-year-old then underwent surgery at Mackay Hospital.

“This is the last thing you would think is going to happen … it was quite brutal,” Mr Thompson said.

“(Clifford’s) doing all right today. It bit him twice. He’s a tough little bugger.”

The family had only moved into the north Queensland home five days before the attack.