We are not alone. Here are a few facts about Steven Spielberg’s 1977 UFO classic, on its 40th anniversary.

1. IT WAS INITIALLY A VERY DIFFERENT FILM.

Spielberg’s initial story outline involved UFOs and shady government dealings following the Watergate scandal, which became a script entitled “Watch the Skies.” The idea involved a police or military officer working on Project Blue Book, the Air Force’s official study into UFOs in the 1950s and 1960s, who would become the whistleblower on the government cover-up of aliens. There were numerous rewrites—Taxi Driver scribe Paul Schrader even took a crack at it, penning a political UFO thriller titled “Kingdom Come” that Spielberg and the movie studio rejected—before the story we know today emerged.

2. IT’S NAMED AFTER LEGITIMATE UFO RESEARCH.

Columbia Pictures

Spielberg partly based his idea on the research of Dr. J. Allen Hynek, a civilian scientific advisor to Project Blue Book who eventually admitted that 11 percent of the study’s findings about unidentified flying objects could not be explained using science.

The title (which is never specifically explained in the movie) is actually derived from Hynek’s own alien close encounter classification system: A close encounter of the first kind is sighting of a UFO; the second kind is physical evidence to prove the existence of an alien; and the third kind is actual contact with alien life forms.

3. THERE’S A CAMEO FROM THE GODFATHER OF UFO RESEARCH.

Hynek, who also served as a technical advisor on the movie, makes an uncredited cameo in the final scene of the movie. You can spot him pretty easily—he’s the goateed man smoking a pipe and wearing a powder blue suit who pushes through the crowd of scientists to get a better look at the aliens.

4. NOBODY WANTED THE STARRING ROLE.

Columbia Pictures

The director first offered the part of Roy Neary to actor Steve McQueen, who turned it down because he said he couldn’t cry on cue, something he saw as essential to the character. Spielberg then went to Dustin Hoffman, Al Pacino, Jack Nicholson, Gene Hackman, and James Caan who all turned him down as well before asking his friend Richard Dreyfuss, who previously worked with Spielberg on Jaws, to take the part.

5. BUT IT WASN'T THE MOST DIFFICULT ROLE TO CAST.

Spielberg approached French actors like Lino Ventura, Yves Montand, and Jean-Louis Trintignant to play Claude Lacombe—who was based on famous UFO researcher Jacques Vallée—before settling on director and sometimes-actor François Truffaut. The initially skeptical Truffaut, who was nervous about appearing in a big budget Hollywood movie, accepted the role because he wanted to compile research for a book about acting (he never did write the book).

6. MERYL STREEP COULD HAVE PLAYED ROY'S WIFE.

Many actresses—including a then-unknown Yale Drama School grad named Meryl Streep—auditioned for the part of Roy’s wife Ronnie, but he ultimately cast actress Teri Garr because he saw her in a coffee commercial and loved the way she was able to convey a wide range of emotions in a 30-second clip.

7. THEY SHOT IN A DISUSED AIR FORCE HANGAR.

Columbia Pictures

Spielberg wanted to shoot in real suburban locations rather than studio backlots, but the production had trouble finding locations. The biggest question: Where could Spielberg shoot the climactic canyon sequence with the mothership?

The production looked for huge indoor enclosures that would allow for the massive scale of the scene, though they only found ones with center support dividers that spoiled the openness Spielberg wanted for the UFO runway. The only location producers found without center dividers was a 300 foot by 300 foot disused hangar that had been used for dirigibles during World War II at Brookley Air Force base in Mobile, Alabama.

8. THE TEAM BOUGHT A HOUSE FOR THE PRODUCTION—AND SOLD IT FOR A PROFIT.

The Nearys' house, which is located at 1613 Carlisle Drive East in Mobile, was actually purchased by the production for $35,000 so they could do whatever they wanted with the interiors. It was later sold for $50,000 after production wrapped, netting a $15,000 surplus that went back into the film’s budget.

9. THE MEMORABLE 5-NOTE TONES TOOK A LONG TIME TO FIGURE OUT

Composer John Williams worked with Spielberg to come up with the movie’s distinct five-note musical method of communication between humans and aliens—which Spielberg partly based on the Solfège system of musical education—a year before shooting began.

Williams initially wanted a seven-note sequence, but it was too long for the simple musical “greeting” Spielberg wanted. The composer enlisted a mathematician to calculate the number of five-note combinations they could potentially make from a 12-note scale. When that number proved to be somewhere upwards of 134,000 combinations, Williams created 100 distinct versions, and they simply whittled the combinations down one by one until they had a winner.

10. SPIELBERG USED TRICKS TO GET THE PERFORMANCE OUT OF HIS CHILD ACTOR.

Columbia Pictures

Cary Guffey, who plays little Barry Guiler, had never acted before, so Spielberg set up ways to coax a performance out of the 3-year-old. To get a shot of Guffey reacting to the aliens first approaching the Guiler house, Spielberg slowly unwrapped a present for the young actor just off camera, making him smile. Guffey even exclaims “Toys! Toys!” in the final take.

To get the boy to react to the aliens offscreen, Spielberg had Guffey walk up to his mark where—unbeknownst to the little actor—two crewmembers were dressed as a gorilla and a clown standing behind cardboard blinds. When Guffey entered the kitchen, Spielberg dropped the first blind revealing the clown to scare him, and then dropped the other blind to reveal the gorilla, which scared him even more. The gorilla then took off his mask, revealing the film’s makeup man, Bob Westmoreland, who Guffey recognized, causing him to laugh and smile in the final take.

11. THE MOVIE NEARLY FEATURED VERY EARLY CGI.

Spielberg originally toyed with the idea of using computer generated images to create the aliens and their ships, even going so far as to have animator Colin Cantwell create a CGI test of three UFOs floating over a stadium. The single-shot test, which took three weeks to complete and was one of the first computer generated images ever created for a film, proved to be unfeasible for the whole movie—so the idea was dropped.

12. THERE WERE SOME UNORTHODOX IDEAS FOR CREATING THE ALIENS.

Spielberg wanted the aliens to be non-human beings that glided instead of walked, and he had a weird idea to pull it off: An orangutan dressed in a specially-made suit. For a screen test, the production team outfitted an orangutan in grey spandex and strapped it into roller skates. The orangutan immediately took off the skates and crawled to its owner, so a full test couldn’t be completed, and the team scrapped the idea. The majority of the small aliens in the final movie were played by local elementary school girls from Mobile in specially made grey suits and masks who were heavily backlit to create the final alien silhouette effect.

13. CLOSE ENCOUNTERS FEATURES A PRECURSOR TO E.T.

Columbia Pictures

To create the alien who bids farewell using the musical hand signals at the end of the film, Spielberg enlisted the help of Italian special effects artist Carlo Rambaldi, who designed a fully articulated steel, aluminum, and fiberglass animatronic puppet that Spielberg nicknamed “Puck.” Puck’s expressions were based on photos of Guffey. The puppet was operated by a crew of seven puppeteers, with Spielberg himself controlling the final articulation before the alien leaves to go to the mothership.

Puck would help inspire E.T. after Spielberg asked himself, “What if this little guy didn’t get back on the mothership?” Rambaldi would also go on to design the character of E.T.

14. SPIELBERG BET AGAINST HIS OWN MOVIE—AND REALLY CASHED IN.

Spielberg and his buddy George Lucas both had new movies coming out in 1977; Lucas’s was a little movie called Star Wars. Lucas thought his ramshackle space movie wouldn’t make back its budget, and he knew his friend’s new movie would break box office records just like Jaws had done, so he offered Spielberg a friendly wager. Both agreed to give the other 2.5 percent of the profits of their respective films. Lucas grossly underestimated his movie, which went on to become the second highest grossing movie of all time if adjusted for inflation (in comparison, Close Encounters is #71). The difference ended up being $40 million.

15. SPIELBERG DIDN'T LIKE THE VERSION THAT WAS INITIALLY RELEASED.

Spielberg wanted to release Close Encounters in the summer of 1978, which would have given him ample time to edit the film and finish its special effects—but Columbia Pictures, which was going through major financial troubles, insisted he have it ready for a November 1977 release, leaving the director with a final cut on a movie he didn’t feel was completely ready.

Three years later, the company allowed Spielberg to “finish” the movie under one condition: That he show the inside of the mothership, which would give the studio’s marketing department an angle to sell this new version. The director capitulated, adding new scenes and cutting others to create a “Special Edition.” The director was unhappy with the scene, though, and later cut it for the “Collector's Edition” home video release.

ADDITIONAL SOURCES:Blu-ray special features; Close Encounters of the Third Kind: The Making of Steven Spielberg’s Classic Film; Close Encounters of the Third Kind Diary.