A rabid fox that had Ipswich residents looking over their shoulders after biting three people had its reign of terror brought to an end by a lifelong hunter who killed the diseased beast with a garden rake in order to save one of his beloved chickens.

“I was mowing the lawn and I saw the fox reach through this fence and grab the chicken,” said Scott Waiswilos, pointing to the spot where the animal sank its teeth into his egg-laying pet named Wilma on Sunday.

“I tried to scare it,” he said, “but it didn’t stop, so I grabbed my big, iron rake and went — WHAM — and broke its back.”

The fox, though, wasn’t done. With its back legs paralyzed, and the business end of the rake broken off and stuck in its back, the animal turned its attention to Waiswilos. With its front two paws, Waisilos said, the animal lunged forward.

But, now armed with a harpoon-like splintered handle, Waiswilos — an electric lineman for the town who grew up hunting — ended the battle.

“I stepped and stabbed him a couple of times,” he said. “Then I just held him down until he bled out. After that I just smashed him in the head — because, you know, I didn’t want him to get up.”

Waiswilos’ son was talking to his friend on the phone in the driveway as the battle was unfolding.

The friend told Waiswilos’ son to put the animals inside because there was a dangerous fox on the loose.

“My son said, ‘Well he’s dead now,’” Waiswilos said, with a laugh. “He said ‘My father just killed the thing.’”

Wilma, the 2-year-old chicken who survived the attack, was sitting safely back in her coop and clucked a few times when Waiswilos called her.

“After I was done, I picked her up and put her in the coop,” he said. “This is the first time I let the chickens out since this happened.”

He has three other chickens — Betty, and Thelma and Louise. Thelma and Louise were also out in the yard last night.

Waiswilos said he has hunted his whole life and knew there was something wrong with the fox when he saw it. He said he knew foxes usually travel in pairs and he was surprised to see this one alone in the middle of the day.

“For him to be out by himself and not running away when I tried to scare him, something was up,” he said. “I knew there was something wrong with him, but he wasn’t going to bite me.”

Town officials said the fox was sent to the Bulger Veterinary Hospital in North Andover and then to the Massachusetts State Laboratory Institute to be tested for rabies. The state confirmed early Tuesday with Ipswich Animal Control that the fox was rabid, authorities said.

On Facebook, friends reached out to him because they knew “it had to be Scott” when they found out the fox was killed on his street.

“I wasn’t going to let him off easy,” he said. “He was coming after my chicken.”

Kristen Giddings contributed to this report.