A potassium flame is visible through cobalt glass due to the color absorption properties of the blue glass. Cobalt glass absorbs the yellow color produced by sodium contamination in a sample, leaving only the purple light produced by potassium.
Sodium's yellow flame and lithium's red flame are both brighter than the purple flame produced by potassium, making cobalt glass an important diagnostic tool in detecting potassium. Many other metal ions burn with a dimmer flame than sodium, making cobalt glass useful in their detection as well.
This flame test can be carried out with minimal equipment, requiring only basic laboratory equipment. Its simplicity is another contributor to its popularity.