Gov. Dannel Malloy signed a sweeping bill on gun control, mental health and school safety into law on Thursday, more than three months after a deadly shooting at an elementary school in Newtown, Conn. shocked the state and the nation.

The bill passed the House of Representatives early Thursday morning after several hours of debate by a margin of 105-44. The Senate voted in favor of the bill 26-10 a day earlier.

Hundreds...