Jo Biden went on a strange tangent while talking about healthcare disparities. (Getty)

Democratic presidential hopeful Joe Biden sparked confusion with an odd rant about gay bathhouses at a town hall debate on LGBT+ rights.

The former vice president was responding to a question about how he would ease racial disparities in health, including higher HIV rates in black Americans.

He pledged to “make sure there is no ability for hospitals or healthcare providers to discriminate”, stressing the importance of education around HIV and AIDS, before things took an odd turn.

During his answer, Biden digressed from the topic at hand and instead began speaking about the stereotypes which have followed gay men over the years, concluding with a non-sequitur about gay bathhouses.

“Remember, Anderson? Back 15, 20 years ago, when we talked about this in San Francisco, it was all about, well, gay bathhouses,” he told moderator Anderson Cooper.

“It was all about round-the-clock sex. Come on, man. Gay couples are more likely to stay together longer than heterosexual couples.”

The LGBTQ Town Hall went great for Biden, uh pic.twitter.com/QUjQlJI1Xg — Timothy Burke (@bubbaprog) October 11, 2019

Online, reactions to Joe Biden ranged from confused to – well, confused.

Listen I would have been fine going my entire life without hearing Joe Biden day “gay bathhouses! Round the clock sex!” but here we are. Anyways, go to a bathhouse and have as much sex as you want. Queer liberation doesn’t mean monogamy! — Phillip Picardi (@pfpicardi) October 11, 2019

Joe Biden just talked about gay bathhouses and nonstop coitus on live national TV is this regressive or extreme allyship I can’t decide — divad (@dzhoww) October 11, 2019

VP Biden asking Anderson Cooper about gay bathhouses and non-stop sex is the most 2019 thing I have ever heard of. OKAYYYYYYYYY UNCLE, JOE! I SEE YOU! THE AFFORDABLE POPPERS ACT IT IS…#EqualityTownHall — Ali Mafi (@AliFameMafi) October 11, 2019

As many pointed out, San Francisco’s bathhouses were effectively banned in 1984, with the final one closing in 1987 – some 32 years ago.

Joe Biden says “15-20 years ago, in San Francisco, it was all about gay bathhouses and round-the-clock sex.” San Francisco ordered their bathhouses closed in 1984. The last one closed in 1987. — Cthulu-pher Keelty 🏳️‍🌈 (@keeltyc) October 11, 2019

Biden, the front-runner for the Democratic presidential nomination, was one of nine politicians who appeared on stage for the LGBT+ town hall.

During the event he discussed his own legacy on LGBT+ rights, pointing out that he voiced his support for same-sex marriage before then-president Barack Obama.

He said that were he to return to the White House as commander-in-chief, he would withhold foreign aid from countries which persecute LGBT+ people.

Elizabeth Warren, who is currently polling a very close second, delivered the best moment of the night while replying to a question on same-sex marriage.

Morgan Cox, chair of the Human Rights Campaign board of directors, asked how she would respond if an “old-fashioned” supporter told her: “My faith teaches me that marriage is between one man and one woman.”

“Well, I’m going to assume it’s a guy who said that, and I’m going to say, ‘then just marry one woman.’ I’m cool with that,” Warren replied, held for applause and added: “Assuming you can find one.”

Pete Buttigieg, who would become the first openly gay president were he elected, spoke about overturning the ban on blood donations from queer men.

“I remember the moment when I realised that, unlike most initiatives that I spearhead, I can’t lead by example on this one, because my blood’s not welcome in this country,” he said.

“And it’s not based on science; it’s based on prejudice.”