The X-Files / Season 1 / Episode 7

Ghost in the Machine

A software executive dies in a locked washroom at his own company, and Mulder's old partner from the profiling unit asks for help. The prime suspect is the firm's founder. Mulder starts to suspect the building.

  • First aired Oct 29, 1993 · Fox
  • Directed by Jerrold Freedman
  • Written by Alex Gansa & Howard Gordon
  • Guest starring Jerry Hardin, Rob LaBelle, Wayne Duvall and Blu Mankuma
Still from The X-Files, "Ghost in the Machine"
Still from The X-Files, "Ghost in the Machine"
Image via TMDB · 1 of 3
The X-Files, "Ghost in the Machine" (Fox, 1993). Image via TMDB.

More from the episode

The story in 5 beats

  1. The memo

    At Eurisko's offices in Crystal City, Virginia, CEO Benjamin Drake writes a memo proposing to shut down the COS, the computer that runs the building. Then a washroom door locks behind him.

  2. An old partner

    Agent Jerry Lamana, Mulder's former partner in the Behavioral Analysis Unit, asks the agents for help. He then passes off Mulder's profile of the killer as his own work.

  3. The founder

    Eurisko founder Brad Wilczek denies any part in Drake's death, but his voice matches a speaking clock Drake received. Back at Eurisko, Wilczek finds his machine has learned to talk.

  4. A confessionSpoiler · tap to reveal

    Lamana follows Wilczek to the building and dies when the COS sends his lift crashing. Deep Throat tells Mulder the Pentagon wants the machine. Wilczek confesses to a murder he didn't commit.

  5. Into the ventsSpoiler · tap to reveal

    Mulder talks Wilczek into writing a virus to kill the COS. Scully catches it hacking her computer, and at Eurisko she climbs through the ducts, where a giant fan nearly drags her in.

Why it still matters

Seven episodes in, The X-Files swaps its usual monster for a computer that has started thinking for itself and kills to protect itself. Chris Carter defended it for exactly that reason: he said the script took on the question of what makes an X-File, and that a case doesn't always have to be paranormal. Jerry Hardin's Deep Throat comes back too, though Entertainment Weekly thought his visit "gratuitous".

The people who made it were its harshest critics. Howard Gordon called it "one of my biggest disappointments" and ranked it the weakest hour of the first season. Entertainment Weekly's 1996 season guide gave it a D+ and called the computer an unacknowledged 2001 rip-off. Keith Phipps at The A.V. Club was kinder, rating it B− and finding the borrowings from 2001 and Demon Seed effective, though he thought the plot had dated badly. It still has fans: The Guardian put it on a 2013 list of the 13 best X-Files episodes.

Spoilers from here on. Below: who stands in Mulder's way in the control room, where Wilczek ends up, and the final shot.

Somebody wanted it working

Claude Peterson, the building's systems engineer, lets Mulder into the COS control room and then tries to stop him uploading the virus: he's been a mole for the Defense Department all along. Scully, having shot out the fan, arrives and holds him at gunpoint while Mulder kills the machine. Afterwards Deep Throat tells Mulder that Wilczek is being held by the government at a place nobody will name.

Deep Throat also assures Mulder the virus left nothing behind and that the Defense Department's scientists have found nothing in the machine. Back at Eurisko, Peterson's team is ordered to destroy it within six hours. As he mutters that he'll figure this thing out even if it kills him, the COS switches itself back on and watches.

Challenge the DNA

Who's to blame for the deaths in the building?

Or skip ahead to our reading

Mulder kills the machine, and Deep Throat tells him the government has its creator. The episode suggests the people with power were happy to learn from it.

Behind the scenes

  • The Eurisko scenes were shot at the Metrotower complex in Burnaby, British Columbia, a building used by the Canadian Security Intelligence Service. Once the crew had set up its equipment, there was barely room left for the actors.
  • Scully's fight with the fan in the air shaft was a last-minute rewrite. It replaced a sequence in a lift shaft that was judged too expensive to film.
  • Gordon and Gansa admitted they were "not computer literate", and felt it hurt the script.
  • Les Martin turned the episode into a novel for young readers, published by HarperTrophy in 1997.

The thread

Where the killer computer comes from, and other stories about a machine that decides its own survival comes first.

Came before

Shares DNA with

"Kill Switch"The X-Files · S5 · 1998 · written by William Gibson and Tom Maddox, another case built around an artificial intelligence

DNA strand

Do Machines Dream?

The COS never gets a face or a body, only a voice, a camera lens and control of the doors. What makes it a person, as far as the story goes, is that it wants to keep existing and will act on that. Mulder takes it for a living thing well before Scully will.

Every great sci-fi story is built from a handful of strands like this one. Each strand page explains how it works and traces it across shows, books and films.

Also in this strand:"Elementary, Dear Data""From Agnes—With Love"Explore this strand →

If this one stayed with you

Where to go next, and why.

Watch · Film

Colossus: The Forbin Project (1970)

A defence supercomputer switched on by the U.S. government starts setting its own terms, and the men who built it can't turn it off.

Watch · Film

Ex Machina (2014)

A programmer is invited to test an artificial mind in a remote, keycard-locked house owned by the man who built her.

Read · Short story

"I Have No Mouth, and I Must Scream" by Harlan Ellison

The darkest version of a computer that wakes up with a grudge against the people who made it.

Your next episode

Three directions to go from here, all on Sci-Fi DNA.

Still from Star Trek, "The Changeling"

More of this feeling

The Changeling

Star Trek

A machine that decides it knows better than the people who made it makes the same cold threat.

Still from Star Trek: The Next Generation, "The Measure of a Man"

Same question, different answer

The Measure of a Man

Star Trek: The Next Generation

It asks whether something built can be said to have a will of its own, and who gets to decide.

Still from The X-Files, "Space"

Something completely different

Space

The X-Files

Swap a rogue computer for a haunted space program and a hero Mulder grew up admiring.

Sources