Nearly two-dozen firefighters and other emergency personnel rescued an injured hiker who couldn't walk out of a mile-long cave in northern Arizona.

The Coconino County Sheriff's Office said a 44-year-old Cordes Lakes man Monday suffered an ankle injury near the end of mile (1.6 kilometer)-long Lava River Cave, an underground tube that the Coconino National Forest's website says was formed 700,000 years ago by molten rock from a volcanic vent on in what is now Hart Prairie.

Story Continues Below

[RELATED STORY: All 12 boys and their soccer coach rescued from Thailand cave]

The Sheriff's Office said 23 rescue personnel from three agencies were involved in the 3.5-hour operation, which was a challenge because of the cave's darkness and rough terrain.

The hiker was transported to Flagstaff Medical Center for treatment.

The cave is located 14 miles (22.5 kilometers) north of Flagstaff.

Where conditions outside the cave can be hot, inside the cave can range from 32 to 40 degrees Fahrenheit on top of total darkness, and the ground being rocky and uneven.

Click/tap here to download the free azfamily mobile app.

© 2018 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.