US President Joe Biden on Monday local time overturned Donald Trump's ban on transgender people serving in the military, saying "all Americans" qualified to serve should be able to do so.
Mr Biden's new policy was set in an executive order he signed at the White House, the latest in a string of directives aimed at reversing Trump-era policies.
"Simply put, transgender service members will no longer be subject to the possibility of discharge or separation on the basis of gender identity," the White House said in a statement.
It also said the military "thrives when it is composed of diverse Americans who can meet the rigorous standards for military service, and an inclusive military strengthens our national security".
The move undoes the former president's controversial decision in July 2017 to bar transgender personnel from serving "in any capacity" in the military.
As commander-in-chief, the US president has enormous latitude to set Pentagon policies.
Mr Trump chose to nix a plan implemented by former president Barack Obama for the military to start accepting transgender recruits.
Mr Trump had claimed the Obama-era policy was disruptive, expensive and said it eroded military readiness and camaraderie among troops.
But in Mr Biden's order undoing Mr Trump's ban, the White House cited a 2016 study that found "enabling transgender individuals to serve openly in the United States military would have only a minimal impact on military readiness and health care cost."
'Victory over prejudice and discrimination'
Newly appointed Defense Secretary Lloyd Austin said he fully supported Mr Biden's order.
The Defense Department "will immediately take appropriate policy action to ensure individuals who identify as transgender are eligible to enter and serve in their self-identified gender," Austin said in a statement, noting that the Pentagon would pay for all "medically necessary transition related care".
The US military has more than 1.3 million troops, and the Pentagon estimates about 9,000 troops identify as transgender, including about 1,000 who have had gender affirmation surgery or plan to do so.
Mr Trump's ban meant transgender troops who were encouraged to come out under one administration suddenly faced getting booted under another, opening up a legal quagmire for the Pentagon.
A series of lawsuits from impacted military personnel followed, with the Supreme Court ultimately allowing the ban to take effect while the litigation worked its way through lower courts.
The American Civil Liberties Union, which had sued over the ban, welcomed Mr Biden's order as sending "a message that transgender people not only belong in our armed services, but in our country".
The Palm Center think tank, which focuses on sexual minorities in the military, called Mr Biden's order "a victory of evidence-based policy over prejudice and discrimination".
"If you can do the job, you should be allowed to do the job, regardless of who you are," the group said on Twitter.