Jacopo Prisco , CNN Written by

Read more unknown and curious design origin stories here

The rainbow flag, which has become a universal symbol of hope for LGBTQ people around the world, first flew in San Francisco's United Nations Plaza for Gay Pride Day, on June 25, 1978.

It had eight colors -- two more than today's version -- and was designed by Gilbert Baker, an openly gay artist and activist. He had been commissioned to design a symbol for the LGBTQ community by his friend Harvey Milk, the first openly gay elected official in California.

Baker drew inspiration from the US national flag, which had celebrated its bicentennial in 1976, and an actual rainbow, which displays the colors of the light spectrum in roughly the same sequence as the flag. He assigned a meaning to each of the colors: hot pink for sex, red for life, orange for healing, yellow for sunlight, green for nature, turquoise for magic, blue for harmony and violet for spirit.

The first flag measured 30 by 60 feet and Baker, who was then 27 years old, had sewn it by hand. "When it went up and the wind finally took it out of my hands, it blew my mind," he told CNN in a 2015 interview . "I saw immediately how everyone around me owned that flag. I thought: It's better than I ever dreamed."

Gilbert Baker in 2003. Credit: AFP/AFP/AFP/Getty Images

In 2003 a record-setting 8,000 feet long by 16 feet wide rainbow flag flew in Florida. Credit: Getty Images/Getty Images North America/Getty Images

After that successful debut, Baker removed two colors from the design to make it easier to mass produced, dropping pink and turquoise and settling with the current six-hue configuration.

Baker died in 2017, aged 65. In the same 2015 CNN interview, he revealed the rationale behind the design of the flag. "We needed something to express our joy, our beauty, our power. And the rainbow did that," he said.

"We're an ancient, wonderful tribe of people. We picked something from nature. We picked something beautiful."