(Reuters) - A mountain goat drowned after photo-taking onlookers crowded the wild animal at a boat harbor in Seward, Alaska, and it leaped from rocks into the ocean, an official said on Tuesday.

The mountain goat's appearance on the rocks of a breakwater at Seward harbor, less than 130 miles (209 km) south of Anchorage, was unusual and caused a stir, Alaska Department of Public Safety spokesman Tim DeSpain said by phone.

Mountain goats are often seen in the cliffs above the town, which has a population of less than 3,000 people and attracts tourists, but not in the city itself, he said.

The animal swam out into Resurrection Bay but was unable to climb back onto the rocks due to the people standing there gawking at it, which led to it drowning, Alaska State Troopers said in an online dispatch about the incident, which occurred on Saturday.

"It is imperative that wildlife is given adequate space to be able to leave a congested area like downtown Seward," the dispatch from Alaska State Troopers said. It added that the mountain goat's body had been recovered.

The animal's death comes after two tourists at Yellowstone National Park in May found a bison calf alone and took it in their car to a park facility, unaware that interference with newborn animals could cause their mothers to reject them, officials said.

Yellowstone rangers repeatedly tried to reunite the calf with the herd but those efforts failed. Ultimately, the abandoned calf was euthanized because it repeatedly approached people and cars along the roadway, raising safety concerns, officials said.

(Reporting by Alex Dobuzinskis in Los Angeles; Editing by Alan Crosby)