Near the end of the 20th century, the West discovers that a weapon of mass destruction is being constructed inside Outer Heaven, a fortified state founded by a "legendary mercenary" 200 km north of Galzburg, South Africa. The special forces unit FOXHOUND sends top agent Gray Fox to infiltrate the fortress, assess the situation and neutralize the threat. FOXHOUND loses contact with Gray Fox a few days later, with his last transmission being "METAL GEAR..." To discover what happened to Gray Fox, FOXHOUND commander Big Boss sends his newest recruit, Solid Snake, into the area in an operation codenamed Intrude N313.
Upon insertion into Outer Heaven, Snake makes contact with local resistance members Schneider, Diane, and Jennifer. Using all of his skills and the equipment he procures on site, he manages to rescue Fox. Fox explains that Metal Gear is the codename of a nuclear-equipped bipedal walking tank, which can engage in all forms of combat and launch nuclear weapons from any location. Outer Heaven plans to use Metal Gear to impose itself as the new world superpower.
To destroy Metal Gear and topple the Outer Heaven mercenaries, Snake rescues lead Metal Gear engineer Dr. Pettrovich Madnar and his daughter Ellen. The scientist explains how Metal Gear can be destroyed, and Snake takes on Outer Heaven's troops. However, he begins to notice that traps put in his way are too precise, and wonders how information on his activities are being tracked. Big Boss begins to act strangely and eventually tells Snake to abort the mission (breaking the fourth wall by telling the player to turn off the console). Moreover, Schneider is ambushed by hostiles and is presumed dead after losing contact with Snake.
Snake penetrates Outer Heaven's main base and takes out Metal Gear before it reaches completion. As he safely escapes the compound's basement, he is confronted by the mercenary leader of Outer Heaven, who turns out to be Big Boss. The corrupt leader reveals that he had been using his connections to steal military intelligence, establish his own mercenary force, and fund his activities. It was his aim to have Outer Heaven become the world's greatest superpower, able to bring even the West to its knees. He had the rookie Snake sent in, hoping to have him captured and feed misinformation to authorities, but had quite obviously underestimated Snake's capabilities.
Having lost Metal Gear and much of his force, Big Boss seemingly starts the self-destruct sequence for the compound, and promises he will not die alone; Snake will join him. Snake defeats Big Boss in a last battle and escapes the Outer Heaven compound as it crumbles in flames behind him. After the end credits, a message from Big Boss is displayed saying that he will meet Solid Snake again.