Metal salts are used to make the different colors in a firework. The basic chemicals in a firework are potassium nitrate (in the gunpowder) which propels the firework upward once the fuse is lit. The loud bang comes from when the fire reaches the rest of the gunpowder inside the firework. Carbon is one of the main components in the black powder, which also works as a propellant. Iron produces the sparks, Oxygen is the oxidizer (some substances are nitrates, chlorates, and perchlorates) which are necessary for the burning to occur. Sulfur is a component of black powder that also acts as a propellant. Zinc is used to create smoke