A man is lucky to be alive after having been stung between 500 and 1,000 times by tens of thousands of swarming bees near Kingman in northwestern Arizona on Friday, authorities said.

The unidentified man was in stable condition at Kingman Regional Medical Center following the attack after he apparently disturbed a large hive in the backyard of a home, said Mohave County sheriff's spokeswoman Leslie DeSantis.

"The number of bees in the shed was unbelievable," DeSantis said. "The deputy who arrived said it was it was like something you'd see in the movies. It was just amazing."

Authorities said the man was working on the property when he was stung and ran to his vehicle, getting help from two passers-by who were also stung. They were not hospitalized.

A beekeeper called to the scene was also stung 23 times. He told authorities it would probably take several days to fully contain the bees.

Authorities are warning residents of the area to keep pets indoors, avoid walking nearby, and drive through with car windows closed.

The attack took place at a golf-course community with large-lot homes in Valle Vista, about 23 km (14 miles) northeast of Kingman and 332 km (206 miles) northwest of Phoenix.