The Boy Scouts of America says it will allow transgender children who identify as boys to enroll in its boys-only programs.

The Irving-based organization announced Monday that it had made the decision to base enrollment in boys-only programs on the gender a child or parent lists on the application to become a scout.

The group had previously held a policy that relied on the gender listed on a child's birth certificate.

A spokeswoman for the organization says it made the decision based on states and communities changing how gender is defined.

"It came as a big surprise but a pleasant one," said Mark Phariss, a Plano attorney and board member of Equality Texas.

Phariss became an Eagle Scout as a teenager and said he had to hide his gay identity.

"Really, the Boy Scouts now have finally come into the 21st century and recognized that scouting, which did so much for me, can now be available and help all scouts, all boys," he said.

An 8-year-old transgender child in Secaucus, New Jersey, was asked late last year to leave his Scout troop after parents and leaders found out he is transgender.

But the statement issued Monday said the change was made because of the larger conversation about gender identity going on around the country.

"For more than 100 years, the Boy Scouts of America, along with schools, youth sports and other youth organizations, have ultimately deferred to the information on an individual's birth certificate to determine eligibility for our single-gender programs," the statement said. "However, that approach is no longer sufficient as communities and state laws are interpreting gender identity differently, and these laws vary widely from state to state."

The Boy Scouts said the enrollment decision goes into effect immediately.

Boy Scouts of America leaders lifted a blanket ban on gay troop leaders and employees in July 2015 amid intense pressure. The group had, after heated internal debate, decided in 2013 to allow openly gay youth as scouts.

The national Girl Scouts organization, which is not affiliated with the Boy Scouts, has accepted transgender members for years.

Effie Delimarkos, the director of communications for the Boy Scouts of America, released the following statement Monday evening: