From National Geographic:
Known in the weather world as a circumhorizontal arc, this rare sight was caught on film on June 3 as it hung over northern Idaho near the Washington State border.
The arc isn’t a rainbow in the traditional sense—it is caused by light passing through wispy, high-altitude cirrus clouds. The sight occurs only when the sun is very high in the sky (more than 58° above the horizon). What’s more, the hexagonal ice crystals that make up cirrus clouds must be shaped like thick plates with their faces parallel to the ground.
When light enters through a vertical side face of such an ice crystal and leaves from the bottom face, it refracts, or bends, in the same way that light passes through a prism. If a cirrus’s crystals are aligned just right, the whole cloud lights up in a spectrum of colors.
This particular arc spanned several hundred square miles of sky and lasted for about an hour, according to the London Daily Mail.