Cotton candy was not invented by a doctor, but rather by a dentist. William Morrison, a dentist from Nashville, Tennessee, and John C. Wharton, a confectioner, co-invented the cotton candy machine in 1897. They introduced the sweet treat, originally called "fairy floss," at the St. Louis World's Fair in 1904. While it was a dentist who played a role in the invention of cotton candy, it was not specifically a medical doctor.