As the visibility of transgender Americans has increased in recent years, it has been accompanied by a contentious political debate over the rights of the estimated 0.6% of U.S. adults who identify as transgender – in particular, which public restrooms they should legally be allowed to enter.

Earlier this year, North Carolina became the focus for much of this debate when it enacted a law prohibiting people from using public bathrooms that do not match their biological sex. The law has prompted a backlash from some businesses, large organizations and others, including the National Basketball Association and the National Collegiate Athletic Association. It is currently being challenged in court by the Obama administration.

About half of U.S. adults (51%) say transgender individuals should be allowed to use public restrooms that correspond with the gender they currently identify with, according to a new Pew Research Center survey. But nearly as many (46%) take the opposite position – on the side of the North Carolina law – and say transgender people should be required to use bathrooms that match the gender they were born into.

Religion, age, gender and politics are all connected with views on this issue. For instance, a majority of Americans who say they attend religious services at least weekly – especially white evangelicals – say transgender people should be required to use bathrooms of their gender at birth, while most of those who attend services less often (particularly people who do not identify with any religion) take the more liberal position that such individuals should be allowed to use bathrooms that correspond to their gender identity.

Also, more women than men take the liberal stance (55% vs. 45%) as do young adults when compared with older Americans (67% of those ages 18 to 29, compared with about half or fewer in older age groups). In addition, those who are Democrats or who lean Democratic are far more likely than Republicans and GOP leaners (68% vs. 30%) to say transgender people should be able to use the bathroom that fits their gender identity.

In addition, people who say they personally know someone who is transgender are more likely than those who do not to say transgender people should be allowed to use public bathrooms that match their current gender identity (60% vs. 47%). But only 30% of U.S. adults say they know someone who is transgender – far lower than the share of Americans who know someone who is gay (87%).

Finally, only about one-in-five Americans (18%) say they sympathize at least somewhat with both perspectives on the use of public restrooms by transgender people, giving the issue at least the appearance of fitting into the broader pattern of political polarization in America. Indeed, roughly six-in-ten say they sympathize only with one side or the other. An additional one-in-five (19%) sympathize with neither side.

Michael Lipka  is an associate director focusing on news and information research at Pew Research Center.