Patrick Cooper, of Anchorage, was competing in the annual mountain race on Sunday that goes through rugged terrain when he apparently encountered the bear.
He reportedly texted a member of his family to say he was being chased by the animal.
"The mother was here with her family, her children, they were running the race," Nathan Michell, of the Anchorage police department, told reporters.
The race director said the boy had raced up a mountain and was on his way down extremely steep terrain that goes through thick wilderness when the attack took place.
Several fellow runners and rescuers rushed to the site but initially couldn't get close as the animal was still in the area.
"The bear was remaining in the area where the young man was," Tom Crockett, a park ranger with Chugach State Park, told local media.
Cooper's body was found about 500 yards from the trail in heavily wooded terrain.
Bear encounters are not common in the area and it was unclear what prompted the attack, Crockett said.
"This young man didn't do anything wrong. He was just in the wrong place," he told the Alaska Dispatch News.
"You can't predict which bear will be predatory."
(Except for the headline, this story has not been edited by NDTV staff and is published from a syndicated feed.)