A demonstrator from Code Pink for Peace hold up a sign during a hearing of the Senate Armed Services Committee about the military's "don't ask, don't tell" policy on Capitol Hill, Dec. 2, 2010 in Washington, D.C. Chip Somodevilla/Getty Images

The Hague Center for Strategic Studies, an independent research group of the Dutch Ministry of Defense, has released a ranking of countries based on their level of inclusion of lesbian, gay, bisexual and transgender (LGBT) service members in their armed forces. The global ranking is the first of its kind.

Countries were judged based on their level of inclusion, admission and tolerance of LGBT service members, and were penalized based on their level of exclusion or persecution of them.

The top ranked countries on the list are New Zealand, The Netherlands and the United Kingdom. The United States is 40 out of 103 countries, behind Chile, Georgia and Cuba.

Syria, Iran and Nigeria ranked the lowest.

While the U.S. has repealed its controversial "don’t ask, don’t tell" policy, it is the lesser known ban on transgender people serving in the armed forces that has dragged the country down to the lower ranking.

In a document obtained by The Guardian, the Department of Defense (DOD) says that applicants can be rejected if there is a "current or history of psychosexual conditions, transsexualism, exhibitionism, trasvestism, voyeurism and other paraphilias."

A spokesman also told the British newspaper the DOD does not allow transgendered people to serve in the military based on "medical standards for military service."

Joshua Polchar said the U.S. is behind the rest of the world because of the policy.

"There have been big steps since don’t ask, don’t tell and the repeal of DOMA," Polchar, who helped produce the index, told The Guardian. "But the headline story is that the US continues to lag behind on the transgender issue."

"This is also about military effectiveness, as an inclusive and respectful culture benefits straight people, LGBT people and the armed forces as a whole."

There have been considerable advancements for LGBT rights in the U.S. Last year the Supreme Court struck down portions of the controversial Defense of Marriage Act (DOMA), which made it illegal for the federal government to recognize same-sex marriages.

Since that change, same-sex married couples have become eligible to jointly file their income tax, receive spousal death benefits and a host of other benefits previously afforded only to heterosexual married couples.

There are currently five court cases challenging same-sex marriage bans in conservative states. Many of the challenges are expected to make their way to the Supreme Court.

Most recently, Attorney General Eric Holder announced that the Justice Department will also amend its policies to treat same-sex married couples the same as heterosexual couples. The change allows gay couples to invoke "marital privilege" in court, file for bankruptcy together and have the same visitation rights in federal prison as their heterosexual counterparts.

The Hague Center will issue a full report based on the LGBT military index in May. The rankings are available here.