The credit is generally given to the Chinese for the discovery of fireworks along with the gunpowder in the 9th century. According to a popular story, a cook accidentally mixed sulfur, potassium nitrate (saltpetre) and charcoal. He noticed that the mixture was combustible. When the mixture was put in a bamboo and burned, it exploded and that was probably the first fireworks invented during the rule of Sung Dynasty.