President Donald Trump on Wednesday announced the U.S. military won't accept transgender troops – a decision that drew a near-instant reaction online.

In a series of tweets, Trump announced the decision and explained the reasoning behind his reversal of the President Barack Obama-era policy.

"After consultation with my Generals and military experts, please be advised that the United States Government will not accept or allow Transgender individuals to serve in any capacity in the U.S. Military," Trump wrote. "Our military must be focused on decisive and overwhelming victory and cannot be burdened with the tremendous medical costs and disruption that transgender in the military would entail. Thank you."

After consultation with my Generals and military experts, please be advised that the United States Government will not accept or allow...... — Donald J. Trump (@realDonaldTrump) July 26, 2017

....victory and cannot be burdened with the tremendous medical costs and disruption that transgender in the military would entail. Thank you — Donald J. Trump (@realDonaldTrump) July 26, 2017

....Transgender individuals to serve in any capacity in the U.S. Military. Our military must be focused on decisive and overwhelming..... — Donald J. Trump (@realDonaldTrump) July 26, 2017

The military has allowed current transgender troops to serve openly since former Defense Secretary Ash Carter ended the previous ban on their service last year. The service members have also been able to receive medical care and formally change their gender identifications in the Pentagon's personnel system since Oct. 1, according to The Associated Press.

The president's posts were met with swift criticism online from some who argued against the decision and said it was unjust.

The American Civil Liberties Union, for one, tweeted an appeal to transgender service members, saying they "deserve better from their commander-in-chief."

Thousands of trans service-members on the front lines deserve better from their commander-in-chief, @realDonaldTrump. Contact the ACLU. pic.twitter.com/tr9YroUrKo — ACLU National (@ACLU) July 26, 2017

Politicians from both sides of the political spectrum also criticized Trump's decision.

No American, no matter their sexual orientation or gender identity, should be prohibited from honor + privilege of serving our nation #LGBT — Ileana Ros-Lehtinen (@RosLehtinen) July 26, 2017

Transgender servicemembers aren't a distraction, they are dedicated patriots. We welcome their service & honor their love of country. #LGBT — Ed Markey (@SenMarkey) July 26, 2017

The "tremendous medical costs" Trump should focus on are in cruel #Trumpcare proposals that gut #Medicaid and rip away coverage. #healthcare — Ed Markey (@SenMarkey) July 26, 2017

69 years ago, President Truman desegregated the US Military. This morning, @POTUS turned anti-#trans prejudice into policy. — Nancy Pelosi (@NancyPelosi) July 26, 2017

Transgender Americans in military are heroes like anyone else risking their lives to defend us. @POTUS is wrong: https://t.co/3bGVPCdzMI — Cory Booker (@CoryBooker) July 26, 2017

"You ought to treat everybody fairly and you ought to give everybody a chance to serve,” says Sen. Shelby, R-Ala., on CNN. — Gabrielle Levy (@gabbilevy) July 26, 2017

Transgender Americans are serving honorably in our military. We stand with these patriots. — Chuck Schumer (@SenSchumer) July 26, 2017

This is discrimination, plain and simple. I stand with the brave transgender Americans who selflessly serve our military. https://t.co/VGck60O9G1 — Kamala Harris (@SenKamalaHarris) July 26, 2017

And to those of you who’ve put your lives on the line for our country, we are indebted to you. — Tom Perez (@TomPerez) July 26, 2017

Still, some backed Trump's announcement, tweeting support for the decision.



If you are going to serve in the Military

Serve as a Legal MALE or Legal FEMALE

We have NO TIME for Confusion on Gender in the Military https://t.co/9T28ES74HX — Peter Boykin (@peterboykin) July 26, 2017