Photos of a couple being chased by an elephant while they were trying to click a selfie with it on their visit to Khao Yai National Park in central Thailand, about 200km northeast of Bangkok, have gone viral.

The encounter, believed to have taken place on 13 September, was captured by a Facebook user, Kamron Petprayoon, who was taking photos of the male elephant from a safe distance after spotting it on a roadside leading to the national park.

The photos have received around 7,000 likes and have been shared around 2,500 times after Petprayoon posted them on Facebook on 20 September.

"I stopped my car and took photos of the elephant. Drivers of vehicles that followed me along the road spotted it also and refused to drive past it. So I led them past the elephant which appeared to pay no attention to us," he wrote.

"After about 14 kilometres, the elephant was eating leaves when I saw two runners go near the animal and take selfies with it. When they went nearer, I turned to change my lens. When I turned back, I saw the elephant quietly running towards them."

Petprayoon said he shouted "watch out" and the couple began to run.

"When the runners had gone far ahead of the animal, it stopped chasing. But when they stopped running, it chased them again but this time, it made a loud noise. This happened about three times."

The obviously angry elephant then stood in the middle of the road blocking traffic, until it was chased away by park rangers.

The couple are lucky they escaped unharmed, Kanchit Sri-noppawan, chief of the national park, told the Nation news website.

"Such acts are very dangerous because if the elephant gets angry, it could attack and kill them. It's a warning to other tourists as well. They are very lucky that the animal was not very angry," he said.

"People can gauge an elephant's feelings by looking at its ears and tails. If it is moving its ears back and forth, it suggests that it is in a good mood. But if it raises its ears and points its tail, that's a warning that it is very disturbed and could harm people."

A similar incident took place in August at the UK's Trentham Monkey Forest in Tittensor. Karima Nabi, a woman visitor to the zoo, was chased by a Barbary macaque when she tried to take a picture with it.