PrEP is viewed as a "game changer" service in the fight against HIV and Aids
NHS England has lost its appeal over a High Court ruling that it has the legal power to commission a service in the fight against HIV/Aids.
However, thousands of sufferers may still miss out if it decides it does not have enough money to prioritise them over treatments for other conditions.
The NHS previously said that local authorities should provide the pre-exposure prophylaxis drug - known as PrEP - because they are responsible for preventative health. But councils insisted they had too little money.
The potential bill for treatment is high, because the drugs are expensive, estimated at up to £20m a year to treat all those who could benefit. The local authorities have said they cannot afford to pay.
An estimated 14,000 people would be eligible for Prep in England.
NHS England said the judgment confirmed that it had the ability, but not the obligation, to fund Prep.
An NHS spokesman said it would now formally consider whether to fund the drug.
"Second, we will discuss with local authorities how NHS-funded Prep medication could be administered by the sexual health teams they commission.
"Third, we will immediately ask the drug manufacturer to reconsider its currently proposed excessively high pricing, and will also explore options for using generics."
The National Aids Trust (NAT) brought the legal action in June following NHS England’s decision to derail the commissioning process, claiming that prevention fell outside of its remit – despite local authorities also denying responsibility for it.
In April, HIV Ireland urged the incoming government to take action to address the "spiralling" HIV crisis, as ten new people are diagnosed with HIV every week in Ireland.
PrEP is not currently widely available in Ireland.