The Montgomery County Board of Education voted Monday to bar nonprofit groups from distributing fliers to middle and high school students, following protests over a leaflet sent home earlier this year that many students and educators considered anti-gay.

The new policy, approved on a 6 to 1 vote with one member absent, forbids the distribution of leaflets from any outside organization, except government agencies or PTAs. The fliers, which often advertise sports leagues or service projects, can still be posted in designated areas in middle and high schools, and can continue to be sent home with elementary students.

Board members said the controversy that erupted over fliers sent home with students in February prompted them to step back and evaluate whether it made sense to operate a backpack flier program at a time when there are so many other avenues for communication.

Board members also cited the environmental effect of paper fliers, the strain on teacher schedules and the questionable effectiveness of giving fliers to students — who often lose them or throw them away — as reasons for ending the practice.

“The times really are changing,” board President Shirley Brandman (At Large) said.

The old policy permitted nonprofit groups to send fliers home with middle and high school students four times a year, unless the message was considered hate speech. The right was upheld in federal court several years ago, after a religious group sued the school system for refusing to distribute fliers promoting its after-school Bible study programs.

To remain viewpoint neutral, schools must allow any nonprofit — or forbid all nonprofits — from participating.

Laura Berthiaume (Rockville-Potomac) was the only board member to oppose the policy change. “What we are talking about is something that has traditionally been a community service, a community building sort of thing,” Berthiaume said. “I wonder if in doing this . . . we are lowering our community bonds.”

Board member Christopher S. Barclay (Silver Spring) was not present for the vote.

Debate over the district’s flier program was renewed in February after Parents and Friends of Ex-Gays and Gays, a Virginia-based group, distributed fliers to five high schools with the message that homosexuality is not innate and that gay people can change their identities. PFOX has been distributing fliers in Montgomery schools for several years.

Many students and educators, including Schools Superintendent Joshua P. Starr, protested the message, calling it intolerant and potentially harmful to gay students.

Parents, Families and Friends of Lesbians and Gays, along with the Southern Poverty Law Center and the Equality Maryland Foundation, responded to the message in April by distributing 50,000 of their own fliers with the message that homosexuality is not a choice, nor is it something “that voluntarily can be changed.”

Starr said Monday that it was important to rethink the policy. “We have to confront and be very sensitive to the health and well-being of our LGBT students.”

Montgomery County’s revised sex education curriculum, which went into effect in 2007, describes homosexuality as innate. Some advocates have urged the school district to also make explicit that being gay is not a mental illness. The tightly scripted curriculum does not specify this unless children ask.