The Advertising Standards Agency [ASA] has upheld 92 complaints from the British public about a Paddy Power advert which featured transgender people.
The advert was shown in February, just before Ladies' Day at the Cheltenham Festival, and the betting company asked viewers to pick out the "stallions" from the "mares".
Nearly 100 complaints were received by the agency about the advert being offensive towards transgender people and condoning discrimination.
The advert stated: "...we're going to make Ladies' Day even more exciting by sending in some beautiful transgendered ladies. Spot the stallions from the mares".
It showed a camera panning round the racegoers while a voiceover attempted to guess the true gender of each of the women.
The ASA said: "We considered that the ad trivialised a highly complex issue and depicted a number of common negative stereotypes about trans people.
"We considered that by suggesting that trans women would look like men in drag, and that their gender could be speculated on as part of a game, the ad irresponsibly reinforced those negative stereotypes.
"And, particularly by framing the game in a way that involved a member of the public who had commented on Paddy Power's Facebook page, the ad condoned and encouraged harmful discriminatory behaviour and treatment."
Paddy Power said that it did not intend to cause harm or offence and was "saddened" that some viewers had been offended by the ad.
A Paddy Power spokesman said the company was disappointed by the ruling.
He added: "This decision is especially frustrating given that the commercial was pre-approved by British television advertising clearance body Clearcast, who then considered the humour in the advert, while not to everyone's taste, fell short of causing offence.
"Additionally, we reached out to leading UK transgender group, The Beaumont Society, for feedback on the script.
"Furthermore, we exclusively cast members of the trans community in the various transgender roles in the commercial.
"Finally, it is worth pointing out that the commercial has almost 600,000 views with twice as many 'likes' than 'dislikes."'