Penicillin belongs to the beta-lactam family of antibiotics, the members of which use a similar mechanism of action to inhibit bacterial cell growth that eventually kills the bacteria.
Bacteria cells are surrounded by a protective envelope called the cell wall. One of the primary components of the bacterial cell wall is peptidoglycan, a structural macromolecule with a net-like composition that provides rigidity and support to the outer cell wall. In order to form the cell wall, a single peptidoglycan chain is cross-linked to other peptidoglycan chains through the action of the enzyme DD-transpeptidase (also called a penicillin binding protein—PBP). Throughout a bacterial lifecycle, the cell wall (and thus the peptidoglycan crosslinks) is continuously remodeled in order to accommodate for repeated cycles of cell growth and replication.
Penicillins and other antibiotics in the beta-lactam family contain a characteristic four-membered beta-lactam ring. Penicillin kills bacteria through binding of the beta-lactam ring to DD-transpeptidase, inhibiting its cross-linking activity and preventing new cell wall formation. Without a cell wall, a bacterial cell is vulnerable to outside water and molecular pressures, and quickly dies. Since human cells do not contain a cell wall, penicillin treatment results in bacterial cell death without affecting human cells.
Gram-positive bacteria have thick cell walls containing high levels of peptidoglycan, while gram-negative bacteria are characterized by thinner cell walls with low levels of peptidoglycan. The cell walls of gram-negative bacteria are surrounded by a lipopolysaccharide (LPS) layer than prevents antibiotic entry into the cell. Therefore, penicillin is most effective against gram-positive bacteria where DD-transpeptidase activity is highest.