When Top Gun blasted into theaters in 1986 it became a box office smash and sent Tom Cruise’s star soaring to new heights.

If there was one track that summed up the film’s high-adrenaline attitude, it was the closing credit song “Danger Zone,” performed by Kenny Loggins. The track, written by Georgio Moroder and Tom Whitlock, became an iconic piece of mid-‘80s movie music. Still, things could have gone much differently.

Producers Don Simpson and Jerry Bruckheimer enlisted Harold Faltermeyer to compose the film’s score. The men had worked together on a different hit movie, 1984’s Beverly Hills Cop. In addition to Faltermeyer’s epic score, the producers wanted to use an assortment of original and pre-existing songs throughout the film.

“The producers and the music supervisor came to the studio with over 300 songs to audition against various scenes,” Whitlock recalled in a 2014 interview. “There was a Sony TV in the studio and they would run footage and play bits of songs against various scenes.”

The filmmakers used this testing process to whittle down song options for various moments in the film. Despite having plenty of music to choose from, they couldn’t find the signature closing track.

“Nothing seemed to be working very well so (if I remember correctly) Jerry asked Giorgio to write something,” Whitlock explained. “Giorgio came up with the track that became ‘Danger Zone.’”

Moroder developed the song’s melody, while Whitlock crafted the lyrics. Session singer Joe Pizzulo sang the track’s demo, which garnered a positive response from the producers. With their climactic tune coming together, filmmakers sought an A-list artist to record the final product. Their search would not be easy.

“Since there was a soundtrack album deal in place, it took a while to figure out who was going to sing ‘Danger Zone,’” Whitlock recalled, noting that the record company behind the band’s soundtrack “wanted an artist that was signed to their label.” Several notable artists would be approached for the project, only to pass. Singer Bryan Adams turned the opportunity down, reportedly because he thought the film glorified war. Corey Hart declined, wanting instead to focus on works he’d written himself. REO Speedwagon passed for similar reasons.

At one point, it appeared that “Danger Zone” might be recorded by Toto. The group wrote another song for the film, “Only You,” and were reportedly interested in the closing credit tune as well. However, discussions fell apart and “Only You” would instead be released on their 1992 LP Kingdom of Desire.

With "Danger Zone" in hand, but no artist to record it, producers approached Loggins. “I was in the studio, and I had written a track for the movie called 'Playing With the Boys,'” the singer later recalled in a conversation with Movieweb. “There was definitely some other act or bands ahead of me, and it fell out. I just happened to be in the studio, and they needed a singer right away. I dropped what I was doing and went in.”

“Once Kenny Loggins was on board, I went to meet him at a house in Encino and ran the lyrics down,” Whitlock remembered. “He moved some stuff around and had a few ideas. He came over and sang it a few days later. He's masterful in how he uses his voice and extremely adept at recording. It all went down very quickly.”

The experience was a new one for Loggins. Though he’d scored a couple of hits on movie soundtracks -- specifically “I’m Alright” from Caddyshack and the titular song from Footloose -- this was the first time he’d recorded a song penned by someone else.

For that reason, the singer admitted he didn’t have a “heart connection” with the song. Instead, he saw "Danger Zone" as his chance to rock.

Loggins had been fond of Elvis Presley since childhood, regularly stealing the rocker’s album from his older brother. “I would come home early from school, I was the first one home,” the singer recalled during an interview with the Entertaining Insights podcast. “And then I would steal his records and I would always play ‘Hound Dog’ over and over and over again.”

“(Initially) I didn’t know who Elvis Presley was,” Loggins went on to admit. “I just knew the music was amazing. And it was all about fun.” It was that element of fun that he’d channel for his rendition of “Danger Zone.”

Released May 13, 1986 the Top Gun soundtrack would become a massive commercial success. The LP sold more than nine million copies in the U.S. alone, with “Danger Zone” serving as its first single. The song became a quintessential track of the era, peaking at No. 2 on the Billboard chart. Loggins later admitted he was surprised by the success.

“At the time, it seemed like a pretty simple piece of rock and roll,” the singer revealed. “It turned into one of the biggest songs of my career… People love it!”

Decades after the original Top Gun film, a sequel was announced. Naturally, Loggins wondered whether his iconic song would again be featured. He got his answer when he came face to face with Cruise, who he surprisingly didn't meet until both stars appeared on The Tonight Show With Jimmy Fallon in 2020.

“I stopped [Cruise] before we went on and I said, ‘So, yes or no. Is ‘Danger Zone’ in the new movie?’" Loggins recalled. The actor's response? "'We can’t do Top Gun without ‘Danger Zone.’”

The Best Rock Movie From Every Year

More From Ultimate Classic Rock