The UK has exceeded UN targets for HIV diagnosis and treatment, proving efforts to control the epidemic can work.
The number of people newly diagnosed with the infection fell by 17%, from 5,280 in 2016 to 4,363 in 2017.
An estimated 92% of the of 102,000 people living with HIV in Britain have been diagnosed, according to Public Health England (PHE). Of those, 98% are on treatment, and 97% of those on treatment are virally suppressed, meaning HIV is undetectable in their blood.
The figures make the UK one of the first countries to reach the UN's 90-90-90 targets, which urge countries to achieve a 90% success rate in the diagnosis, treatment and viral suppression of HIV, the health body says.
"Many of us will remember a time when an HIV positive result was effectively a death sentence. Today's report is a poignant and powerful reminder of how far we've come," UK Health Secretary Matt Hancock said in a statement. "Now in the UK, almost everyone with HIV is not only diagnosed and in treatment but living long, healthy lives -- and we're one of just a handful of countries to meet these ambitious UN targets."
The UK figures contrast sharply with the alarming findings of a report published earlier this week, which found "disproportionately higher" rates of HIV diagnoses in Eastern Europe than in the West.
The improved results in the UK were put down to increased HIV testing, higher rates of condom use and a reduction in the time between diagnosis and starting treatment. The availability of pre-exposure prophylaxis, or PrEP, is also thought to have had an impact.
PrEP involves the use daily pills -- usually antiretroviral drugs -- to reduce the risk of contracting HIV through sex, and has been shown to be up to 90% effective, according to the US Centers for Disease Control and Prevention.
But more can be done -- an estimated 43% of new HIV diagnoses in 2017 were made at a late stage of infection, the UK figures showed.
"There can be no doubt prevention efforts to end the HIV epidemic in the UK are working," said Professor Noel Gill, Head of STIs & HIV at Public Health England.
"Our efforts must continue apace in order to eliminate HIV. With an estimated 8,000 people still unaware of their infection it is vital that people seek out an HIV test if they consider themselves at risk, or accept the offer of an HIV test by a healthcare professional, as early diagnosis is key to stopping transmission."
The UK results represent a "great achievement," said Sarah Fidler, professor of HIV and communicable diseases at Imperial College London, who was not involved with the report.
She praised the work of British health agencies, which have "harnessed resources, media, advocacy and messaging around HIV testing."
"The challenge we now face is how to ensure we can sustain these services in the UK," Fidler added. "If we are to maintain the momentum, we cannot afford complacency. Any reduction in HIV prevention or the care of patients with HIV threatens these amazing achievements."
Around 39 million people were living with HIV/AIDS worldwide in 2017, according to UNAIDS, the United Nations program that sets international targets.
Globally, about 75% of people living with HIV/AIDs were diagnosed, the group says.