The concept is called a "circumhorizontal arc". It's an atmospheric phenomenon in which sunlight strikes airborne ice crystals to produce a rainbow effect. Four things have to happen for this to be seen:
- The sun has to be higher than 58 degrees above the horizon.
- There has to be a mild haze, such as cirrus clouds, slightly overcast, a marine layer, etc.
- The clouds must contain flat, hexagonal ice crystals.
- You have to be standing farther than 55 degrees latitude away from either pole.
For these reasons, the rarity of the event causes it to only be visible from certain parts of the world at certain times of the year. In North America, it's most commonly observed inland and to the north during the colder months, although as long as there's ice in the clouds and you're standing in the right spot, it could happen anywhere.
Because of the rarity of the event and the strange cloud formations that sometimes occur in conjunction with it, the phenomenon could be mistaken for things like UFOs and other conspiracy-laden legends.