ES News email The latest headlines in your inbox twice a day Monday - Friday plus breaking news updates Enter your email address Continue Please enter an email address Email address is invalid Fill out this field Email address is invalid You already have an account. Please log in Register with your social account or click here to log in I would like to receive lunchtime headlines Monday - Friday plus breaking news alerts, by email Update newsletter preferences

Brazil's supreme court has officially criminalised homophobia and transphobia.

The court’s final justices cast their votes on Thursday for a tally of eight votes for and three against.

The ruling comes amid fears the country's far-Right administration is seeking to roll back LGBT social gains.

Six of the Supreme Federal Tribunal's 11 judges had already voted in favour of the measure in late May, giving the ruling a majority ahead of Thursday's final ballot.

Racism was made a crime in Brazil in 1989 with prison sentences of up to five years.

The court's judges ruled that homophobia should be framed within the racism law until the country's congress approves legislation specifically dealing with LGBT discrimination.

They have said that the ruling was to address an omission that had left the LGBT community in the country legally unprotected.

"In a discriminatory society like the one we live in, the homosexual is different and the transsexual is different. Every preconception is violence, but some impose more suffering than others," said Justice Carmen Lucia.

Justice Ricardo Lewandowski, one of the judges who voted against the measure, recognised the lack of congressional legislation on the issue.

But he said he voted against putting homophobia inside the framework of the racism legislation because only the legislature has the power to create "types of crimes" and set punishments.

While same-sex marriage is legal in Brazil, it is still a dangerous country for members of the LGBT community and has a large evangelical movement often critical of gay rights.

According to the rights group the Grupo Gay da Bahia, 420 LGBT people were killed across Brazil in 2018, while at least 141 have been killed so far this year.

President Jair Bolsonaro, a former army captain who assumed office on January 1, has a history of offensive comments about gays, blacks and other minorities, openly acknowledging he is a homophobe.

He has said he would rather have a dead son than a gay son.

Agencies contributed to this report.