IOWA CITY, Iowa — The 2012 massacre at Sandy Hook Elementary School, in which a mentally troubled young man killed 26 children and educators, served as a rallying cry for gun-control advocates across the nation.

But in the three years since, many states have moved in the opposite direction, embracing the National Rifle Association’s axiom that more “good guys with guns” are needed to deter mass shootings.

In Kansas, gun owners can now carry concealed weapons without obtaining a license. In Texas, those with permits will soon be able to carry openly in holsters and bring concealed weapons into some college classrooms. And in Arkansas, gun enthusiasts may be able to carry weapons into polling places next year when they vote for president.

Dozens of new state laws have made it easier to obtain guns and carry them in more public places and made it harder for local governments to enact restrictions, according to a review of state legislation by The Associated Press. The number of guns manufactured and sold and the number of permits to carry concealed weapons have also increased, data show.

The trend has been discouraging to some gun-control advocates, even as other states have adopted stricter background checks.

Other gun-control supporters say their movement is emboldened by the recent rise of Everytown for Gun Safety, a well-funded group backed by former New York City Mayor Michael Bloomberg that is becoming influential in some state capitols.

The debate over gun rights moved to states after Congress rejected a bill in 2013 that would have expanded background checks to all gun sales, including those at gun shows and over the Internet. The arguments are expected to intensify next year as legislatures convene in the wake of the mass shooting of county government employees in San Bernardino, California.

Recent mass shootings at a Planned Parenthood clinic in Colorado, a community college in Oregon and a church in South Carolina have also reignited passions on both sides.

The pro-gun legislation reflects a growing public sentiment that “gun-free zones are magnets for bad guys,” said David Kopel, a gun-policy expert at the Independence Institute, a libertarian think tank in Colorado. He said that concept was not popular after the 1999 shooting at Columbine High School in Colorado, but the frequency of mass shootings since then has made the idea of having a trained, law-abiding gun owner present more appealing.

On the day after Thanksgiving, gun sales approached a single-day record. More than 185,000 background checks were initiated, the most in the program’s 17 years, the FBI says.