A 14-year-old boy was arrested in Saudi Arabia after dancing the Macarena in the street.

Footage posted on social media shows the teenager wearing headphones and walking into the middle of a road in front of stopped cars.

After smiling at the camera he then breaks into the well-known dance routine in the middle of Tahlia Street in the coastal city of Jeddah.

The state-linked Sabq news website quoted Colonel Aati bin Attiyah al-Qurashi as saying police had arrested the child on Tuesday.

It was later reported that the boy was released after his father signed a pledge vowing to protect his son and not violate "public morals".

Many social media users have defended the teenager, with some even calling him a "hero".

However, others have suggested his behaviour was "immoral".

Some on social media have called the teenager's behaviour 'immoral'. Credit: Twitter

Western music and dancing in Saudi Arabia is taboo, but traditional dance is allowed.

Earlier in August, Saudi singer Adballah Al Shahani was reportedly arrested for performing "dabbing" onstage.

The dance move - which involves a person tucking their head into their arm - is banned in Saudi Arabia because local authorities in the deeply conservative country say it is a reference to drugs culture and advocates or encourages it.

Other social media users have backed the boy. Credit: Twitter

In 2014, six young Iranians were arrested and forced to apologise on state television after posting a video online of them dancing to Pharrell Williams' song "Happy".Three men and three unveiled women were seemingly joining in with the global trend of dancing to the song and uploading the video to YouTube.

However, authorities in the country believed the "vulgar clip... hurt public chastity".