Root beer is traditionally made from the sassafras root which American Indians used as a medicine. It started being sold in confectionary stores in the 1840s and was marketed as a medicine.
Sassafras ended as an ingredient in 1960 when the FDA banned safrole, the oil it contained. Laboratory animals developed liver damage and cancer after getting large doses.