Shortly after the events of Star Trek II: The Wrath of Khan, the USS Enterprise carrying the combined crews of both Enterprise and USS Reliant, limps back to Earth, scarred from its battle with Khan. Once there, Admiral James T. Kirk is informed that the obsolete vessel's days are over (it is stated to be 20 years old, but official production timelines place it as about 40 years old, with Kirk's command of the Enterprise being about 20 years); it won't be refitted, but will instead be retired, and its crew reassigned. Meanwhile, Dr. Leonard McCoy exhibits strange behavior, somehow related to the deceased Captain Spock. He even seems to be channeling both Spock's behavior and voice.
Simultaneously, Kirk's son Dr. David Marcus and Lieutenant Saavik are now on board the research vessel USS Grissom to explore the Genesis Planet, created at the end of the last film. The two transport down to the planet's surface to explore its terraforming progress. While there, they discover, much to their shock, that Spock's body has been resurrected by the Genesis effect, although his mind is no longer present and he operates on a purely child-like level. Marcus, pressed by Saavik, admits that he used unstable 'proto-matter' in building the Genesis device to solve 'certain problems'. Without it, he claims that the Genesis Project could have been delayed by years or would have never been completed at all. The unstable matter puts the planet in a state of accelerated evolution that will conclude with the planet's premature destruction.