Methylene blue was developed in the 1800s as a cobalt blue synthetic dye for textiles, but it also has some medicinal uses. It's approved to treat a rare blood disorder called methemoglobinemia.