Police in Tehran said they had arrested six Iranians suspected of posting a version of US singer Pharrell Williams's hit song Happy on the internet.
The clip shows three men and three unveiled women singing and dancing to the tune in the streets and on Tehran rooftops.
"After a vulgar clip which hurt public chastity was released in cyberspace, police decided to identify those involved in making that clip," the ISNA news agency quoted Tehran police chief Hossein Sajedinia saying on Tuesday.
"Following a series of intelligence and police operations and after coordinating with the judiciary, all the suspects were identified and arrested."
ISNA said the detainees were three men and three women and that they "confessed to their criminal acts".
Pharrell's Happy has become akin to a modern-day ode to joy, with internet users around the world posting video clips of themselves and their friends lip-synching to the song.
Under Islamic law, in force in Iran since the 1979 revolution, women must cover themselves from head to toe. More than a decade ago a "morality police" unit was formed to verify that women scrupulously respect the dress code in public.