The history of science fiction films parallels that of the motion picture industry as a whole, although it took several decades before the genre was taken seriously. Since the 1960s, major science fiction films have succeeded in pulling in large audience shares, and films of this genre have become a regular staple of the film industry. Science fiction films have led the way in special effects technology, and have also been used as a vehicle for social commentary.

Silent film

Science fiction films appeared very early in the silent film era. The initial attempts were short films of typically 1 to 2 minutes in duration, shot in black and white, but sometimes with colour tinting. These usually had a technological theme, and were often intended to be humorous. In Things to Come: An Illustrated History of the Science Fiction Film, Douglas Menville and R. Reginald judged Gugusse and the Automaton to be the most significant scientifically themed film of 1897, and suggested that it “may be the first true SF [science fiction] film.” However, A Trip to the Moon, created by Georges Méliès in 1902, is often considered to be the first science fiction film. It drew upon Jules Verne and H. G. Wells in its depiction of a spacecraft being launched to the Moon in a large cannon. Its ground-breaking special effects pioneered the way for future science-fiction films, and it became largely popular after its release.

Science fiction literature would continue to influence early films. Jules Verne's 1870 classic novel Twenty Thousand Leagues Under the Seas was adapted multiple times, notably into the 1916 film, one of the first feature-length science fiction films. Others, such as Edison Studios' 1910 adaptation of Mary Shelley's 1818 novel Frankenstein; or, The Modern Prometheus, and the 1913 adaptation of Robert Louis Stevenson's Dr. Jekyll and Mr. Hyde, brought the concept of mad scientists to cinema. These two also demonstrated an early overlap between the science fiction and horror genres. Into the 1920s, another success was The Lost World, based on Sir Arthur Conan Doyle's book of the same name. It was one of the earliest examples of stop-motion animation, and also introduced several now-famous science fiction concepts, like monsters, dinosaurs, and lost worlds.

Meanwhile, in Europe, the 1920s displayed a distinct difference from American cinema. European film-makers began to use the genre for prediction and social commentary. In Soviet Russia, the film Aelita discussed social revolution in the context of a voyage to Mars. In Germany, one of the most important pioneers of science fiction was the Expressionist Fritz Lang. His 1927 film Metropolis was the most expensive film ever released up to that point. Set in the year 2026, it included elements such as an autonomous robot, a mad scientist, a dystopian society, and elaborate futuristic sets. His 1929 work Woman in the Moon came as the silent film era was coming to a close, and notably introduced the idea of counting down the time to a rocket launch.

1930s and 1940s Movies during the 1930s were largely influenced by the advent of sound and dialogue, and by the effects of the Great Depression that began in 1929. Audiences began to pursue films with more escapist themes, leading to a decline in serious speculative films. After the failure of the big-budget 1930 American film Just Imagine, studios were reluctant to finance the expensive futuristic sets necessary for this type of film. Although the 1936 British film Things to Come, written by H. G. Wells, projected the world 100 years into the future and forecasted the advent of World War II, it too was a box-office flop, and films with serious speculation and visual spectacle of the future would largely disappear until the 1950s.

Instead, the decade saw the rise of film serials: low-budget, quickly-produced shorts depicting futuristic, heroic adventures. action, melodramatic plots, and gadgetry. The first was The Phantom Empire (1935) starring Gene Autry, about an advanced underground civilization which had ray guns and television communication screens. p 51 Some of the most popular of the era were the various Flash Gordon films, the exploits of Buck Rogers, and others, such as the quasi-science fiction Dick Tracy. They continued to use science fiction elements like space travel, high-tech gadgets, plots for world domination, and mad scientists. Echoes of this style can still be seen in science fiction and action films today, as well as in the various James Bond films.

Other elements of science fiction were carried into the burgeoning horror genre, driven by the massive success of the Universal Studios' Frankenstein and its sequel Bride of Frankenstein. Many Universal Horror films, such as The Invisible Man and Dr. Jekyll and Mr. Hyde prominently featured mad scientists and experiments gone wrong, as did other monster movies like The Vampire Bat, Doctor X, and Dr. Cyclops.

Sequels to successful horror films continued into World War II, and the 1940s also saw the development of patriotic superhero serials like Fleischer Studio's animated Superman short subjects that often doubled as war propaganda. However, science fiction as an independent genre lay mostly dormant throughout the war.

Post-War and 1950s Two events at the end of World War II significantly influenced the science fiction genre. The development of the atomic bomb increased interest in science, as well as anxiety about the possible apocalyptic effects of a nuclear war. The period also saw the beginning of the Cold War, and widespread Communist paranoia in the United States. These led to a major increase in the number of science fiction films being created throughout the 1950s, and creating a Golden Age of Science Fiction that matched the one taking place in literature.

One of the earlier and most important films of the era was the widely publicized Destination Moon, released in 1950. It follows a nuclear-powered rocketship carrying four men to the moon, against a background of competition against the Soviets. With a script co-written by Robert A. Heinlein and astronomical sets by renowned space artist Chesley Bonestell, the film was a commercial and artistic success, and it brought about more studio financing of science fiction films. The producer of Destination Moon was notably George Pal who also helped create When Worlds Collide, The Time Machine, The War of the Worlds, and the pseudo-documentary of crewed space exploration Conquest of Space. Although Conquest of Space was a commercial failure that set back Pal's career, the other four each won an Academy Award for Best Visual Effects, which demonstrated the increased technical excellence and critical recognition of the genre.

Alien films saw a huge surge in popularity during the 1950s. Many featured political commentary being mixed with the concept of UFOs, which had become ingrained in the public consciousness after the Kenneth Arnold and Roswell incidents of 1947. Two of the first were The Day the Earth Stood Still, directed by Robert Wise, and Howard Hawks' The Thing from Another World, with their contrasting views of first contact. While the former had a peaceful race of aliens urging humans to control their use of nuclear weapons, the latter's title creature stalked a crew in the Arctic, with the paranoid final words, "Watch the skies!" The idea of alien invasions as an allegory recurred with Don Siegel's 1956 film, Invasion of the Body Snatchers. Critically acclaimed as a classic, it has been viewed as both a veiled criticism of McCarthyism, or a cautionary story of Communist infiltration.

Another important UFO film, Earth vs. the Flying Saucers, had special effects created by Ray Harryhausen, a master of stop-motion animation that had previously worked with King Kong animator, Willis O'Brien. His work also appeared in such films as 20 Million Miles to Earth, and 1953's hit film, The Beast from 20,000 Fathoms. That film, based on a short story by Ray Bradbury, featured the fictional Rhedosaurus, which is thawed out of the Arctic by atomic testing and begins to ravage sections of the United States. Its massive success set off a new wave of science-fiction monster films. Like the 1930s, these movies demonstrated a mix of horror and science fiction, now often mixed with anxiety of nuclear technology or the dangers of outer space. Them!, It Came from Beneath the Sea, and Tarantula, released within two years of The Beast from 20,000 Fathoms, all featured over-sized animals created by nuclear testing. It! The Terror from Beyond Space, The Blob, The Angry Red Planet, and Kronos, on the other hand, featured alien monsters. Still others, like The Fly, The Amazing Colossal Man, and The Incredible Shrinking Man, focused on human mutation.

This trend was not limited to the United States; perhaps the most successful monster movies were the kaiju films released by Japanese film studio Toho. The 1954 film Godzilla, with the title monster attacking Tokyo, gained immense popularity, spawned multiple sequels, led to other kaiju films like Rodan, and created one of the most recognizable monsters in cinema history. Japanese science fiction films, particularly the tokusatsu and kaiju genres, were known for their extensive use of special effects, and gained worldwide popularity in the 1950s. Kaiju and tokusatsu films, notably Warning from Space (1956), sparked Stanley Kubrick's interest in science fiction films and influenced 2001: A Space Odyssey (1968). According to his biographer John Baxter, despite their "clumsy model sequences, the films were often well-photographed in colour ... and their dismal dialogue was delivered in well-designed and well-lit sets."

The financial success of these films relied on studios drawing in large teenage audiences, taking advantage of popular techniques such as drive-in theaters and 3D, notably used by movies such as Creature from the Black Lagoon or Gog. In addition to increasing the audience size, many science fiction films of the time were created with minuscule budgets; the phrase "B-movie" came to signify a formulaic genre film made with low production costs (usually for less than $400,000). This concept was exemplified in a studio memo about the movie Them! that stated, "We want a picture with the same exploitation possibilities as we had in The Beast from 20,000 Fathoms. We all know this will not be a 'class production' but it has all the ingredients of being a successful box office attraction." The idea of low-quality, low-cost films were taken to an extreme by directors such as Roger Corman, Coleman Francis, and Ed Wood, and the latter's Plan 9 from Outer Space has been hailed as one of the worst films of all time.

However, in the second half of the decade, the steady success of the genre led to some studios attempting serious films with large budgets, including the coldly realistic depiction of a post-nuclear war world, On the Beach, and Forbidden Planet, a science fiction re-imagining of Shakespeare's The Tempest. The second film would influence the genre for years to come; it included the first all-electronic music score, introduced the character Robby the Robot, and served as the inspiration for Gene Roddenberry's Star Trek.

The success of science fiction films also saw the genre grow internationally. In Britain, there was a period of notable production, with Hammer Films adaptations of Nigel Kneale's Quatermass series. The success of the television versions inspired the company to commission a series of film adaptations. Science fiction films also began appearing in Bengali cinema, including Satyajit Ray's 1958 magical realist film Parash Pathar (The Philosopher's Stone), and Ritwik Ghatak's 1958 film Ajantrik (The Unmechanical) that examined the relationship between man and machine.

1960s