A mosque in Malaysia has banned tourists from visiting after a video of two women dancing in front of the site was shared online.

The two women, who were wearing shorts and with bare midriffs, were filmed dancing on a wall in front of the Kota Kinabalu City Mosque on Borneo island.

Authorities are trying to identify the pair, who have been described as foreigners of east Asian appearance.

Footage of the incident has been viewed around 270,000 times on Facebook.

An official from Sabah state's tourism ministry said the video showed a "lack of respect to our Muslim worshippers as well as the hospitality extended" to the visitors.

On Sunday, the mosque's chairman said public transport would not be allowed to bring tourists to the mosque compound, but added that there would be further discussions with tour agencies to prevent similar incidents.

Foreign visitors to mosques in Malaysia are advised to dress modestly.

This is not the first time foreigners have faced trouble for offending public sensitivities in Sabah state.

In 2015, a Malaysian official blamed a group of tourists who stripped naked on top of a sacred mountain for an earthquake which killed 16 people.