Like most rights, the right secured by the Second Amendment is not unlimited. From Blackstone through the 19th-century cases, commentators and courts routinely explained that the right was not a right to keep and carry any weapon whatsoever in any manner whatsoever and for whatever purpose. For example, the majority of the 19th-century courts to consider the question held that prohibitions on carrying concealed weapons were lawful under the Second Amendment or state analogues. Although we do not undertake an exhaustive historical analysis today of the full scope of the Second Amendment, nothing in our opinion should be taken to cast doubt on longstanding prohibitions on the possession of firearms by felons and the mentally ill, or laws forbidding the carrying of firearms in sensitive places such as schools and government buildings, or laws imposing conditions and qualifications on the commercial sale of arms.
We also recognize another important limitation on the right to keep and carry arms. Miller said, as we have explained, that the sorts of weapons protected were those “in common use at the time.” We think that limitation is fairly supported by the historical tradition of prohibiting the carrying of “dangerous and unusual weapons.”
It may be objected that if weapons that are most useful in military service—M–16 rifles and the like—may be banned, then the Second Amendment right is completely detached from the prefatory clause. But as we have said, the conception of the militia at the time of the Second Amendment’s ratification was the body of all citizens capable of military service, who would bring the sorts of lawful weapons that they possessed at home to militia duty. It may well be true today that a militia, to be as effective as militias in the 18th century, would require sophisticated arms that are highly unusual in society at large. Indeed, it may be true that no amount of small arms could be useful against modern-day bombers and tanks. But the fact that modern developments have limited the degree of fit between the prefatory clause and the protected right cannot change our interpretation of the right.
District of Columbia v. Heller, 554 U.S. 570, 626-28, 128 S. Ct. 2783, 2816-17, 171 L. Ed. 2d 637 (2008) (internal citations omitted).