The unanimous vote by the Legislative Council came after nine hearings in which hundreds of residents and non-residents presented more than 200 hours of testimony, The (Danbury, Conn.) News-Times reported Monday.
The ordinance, which goes into effect Oct. 1, limits residents to no more than four hours of shooting after they are notified to stop by the police department. Only one person can shoot at a time and no shooting is allowed within a half-mile of a school.
Target backstops are required and must be 10 feet above the target.
Hunters, military officers and professional law enforcement are not affected by the ordinance. Gun salutes at memorial events and tributes are allowed.
The ordinance was already under consideration at the time of the December shooting at Sandy Hook Elementary School in Newtown in which 20 students and six adults were killed.