Celebrations at the annual Pride In London event are the “best antidote” to the terror and tragedy of recent weeks, Sadiq Khan told thousands gathered in the city.
The Mayor of London said this year’s Pride was the biggest ever, as he addressed revellers in Trafalgar Square.
Members of the emergency services who helped in the aftermath of terrorist attacks and the Grenfell Tower fire disaster launched the march on Saturday afternoon.
Staff from the Metropolitan Police, London Ambulance Service and London Fire Brigade were nominated to take part after helping in response to terrorist atrocities and the Grenfell Fire disaster, organisers said.
They joined flag bearers representing countries around the world, including those where it is still illegal to be LGBT+.
Mr Khan told the crowd: “We’ve had a horrible last few weeks. We’ve had terror, we’ve had tragedy. You know what the best antidote to sorrow, the best antidote to sadness, to bereavement, to hatred, is Pride In London.”
Mention of the DUP, who the Conservative Government struck a deal with following the general election, drew boos from the crowd.
Mr Khan warned that the arrangement with the Northern Ireland party, which is anti-gay marriage and anti-abortion, would not change the status quo in London.
To huge applause, he said: “You (the Government) may have done a deal with the DUP but there will be no backtracking on LGBT+ rights. There will be no backtracking on women’s rights.”
Many in the crowd booed earlier when a video message from Theresa May was played.
In it, the Prime Minister reiterated the UK’s pledge to encourage other countries to ensure equal rights for all, regardless of sexual orientation, and to take a stand against hate crime at home.
She said the UK “will continue to stand up for human rights, directly challenging at the highest political levels governments that criminalise homosexuality or practice violence and discrimination against LGBT Plus people”.
She added: “And here at home too, we must continue to stand up for true equality and respect for everyone, right across our United Kingdom. We must stamp out homophobic bullying in schools, and drive down homophobic and transphobic hate crime.”
More than 26,000 people are estimated to have taken part in the parade which began north of Oxford Circus on Regent Street, watched by a crowd expected to number around one million.
The parade, taking a 1.4-mile route through the city, comes after what is believed to be the world’s largest Pride festival, with over 100 events having taken place since Saturday June 24.
The march is also marking 50 years since the Sexual Offences Act 1967, which decriminalised homosexuality in England and Wales.
As part of the annual Pride weekend, a rainbow flag will be projected on to the Palace of Westminster for the first time.