Search for Spock

The USS Enterprise limps back to Earth heavily damaged after a battle with Khan Noonien Singh (see Star Trek II: The Wrath of Khan). Many were lost in the costly fight, including Admiral James T. Kirk's Vulcan friend, Spock; Spock's casket was shot into orbit around the newly-formed Genesis Planet, created by a torpedo designed to create life from lifelessness. On docking, the Enterprise' crew learns that the ship is due to be decommissioned. Dr. Leonard McCoy is confined by security after he begins to exhibit strange behavior. David and Lieutenant Saavik return to Genesis aboard the research vessel USS Grissom; discovering an unidentified lifeform, Marcus and Saavik beam down to the planet and discover that Spock has been resurrected by the Genesis Device's effects, 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 its premature destruction within a few hours.
Unknown to them, a Klingon commander named Kruge has intercepted information about Genesis and becomes interested in it (for much of the same reasons as Khan: as a weapon). He travels to the Genesis Planet to learn its secrets after stealing additional information related to it.
Spock's father, Sarek travels to Earth and confronts Kirk about abandoning Spock's body on the Genesis planet. Sarek discovers, with Kirk's help, that McCoy possesses Spock's "katra" (soul), which explains his strange behavior. Both his katra and body are needed to properly lay him to rest on his homeworld Vulcan; without swift intervention, Spock's consciousness will overwhelm McCoy, and he will also die. Disobeying direct orders prohibiting anyone from visiting the Genesis Planet, Kirk reunites with his bridge officers and goes through a series of highly unorthodox events such as Uhura charming the watch officer (locking him in a closet), Kirk and Sulu springing McCoy from the Starfleet jail, and Scotty overriding the Starbase security system to open the Starbase doors so the Enterprise can escape, and secondly disabling the pursuing USS Excelsior's "transwarp drive", by removing several circuits.
Kruge arrives at Genesis first, accidentally destroying the Grissom with all hands (save for the landing party). He then summarily executes his weapons officer responsible for the Grissom's destruction as Kruge wanted prisoners. His crew locates and captures the scientists on the planet: David, Saavik, and a now-teenaged Spock. Kirk and the skeleton crew of the Enterprise arrive, unaware that the Klingon ship and its crew are cloaked nearby. Unable to hail the Grissom, the Enterprise crew suspects the presence of a Bird of Prey and are able to strike first, hitting the Klingon ship as it de-cloaks. The Klingon ship returns fire and cripples the automation system controlling the Enterprise. Kruge demands that they surrender, and orders the troops that he had sent to the surface of the Genesis Planet to kill one of the prisoners as a show of strength. David defends Saavik, who was to be the intended victim. David briefly tussles with the Klingon, but is no match with him physically and dies as a result. Kirk is devastated to hear his son has been killed.
Rather than surrender, Kirk orders McCoy and Sulu to the transporter room. Kirk, Scott and Chekov order the ship to self-destruct, and they leave the Enterprise for the last time. The computer countdown confuses the majority of Kruge's crew who had just beamed over to complete the ship's capture and are all killed as the ship self-destructs. The crew of the Enterprise watch from the planet's surface as their home for the last twenty years burns up in the atmosphere. They find Saavik and Spock and free them from their captors. Kirk finds a communcator and tempts Kruge, who is mourning his crew, in an attempt to get him to beam them all up before the planet destroys itself. Moments later, Kruge beams to the planet and has everyone but Kirk and Spock beamed aboard his Bird of Prey. Still demanding the technology of the Genesis project, Kruge engages Kirk in hand-to-hand combat on the disintegrating planet. Kirk tries in vain to get Kruge to cooperate so they can both escape the planet, but Kruge would prefer a fight to the death. Kirk defeats Kruge who subsequently falls into a volcanic rift. Kirk quickly grabs Spock and imitates Kruge's voice shouting the order to beam them both aboard Kruge's ship. The Enterprise crew are able to easily capture the Klingon vessel and the one crewman left on board.
The crew travel to Vulcan, where Spock's katra is reunited with his body in a dangerous procedure called "Fal-tor-pan". Dr. McCoy agrees to the ritual, knowing the extreme risk for both him and Spock. The ritual is successful and Spock is resurrected alive and well, though his memories are still extremely fragmented. The final scene, a brief discussion between Kirk and Spock, ends with Spock slowly remembering the man before him: "Jim. Your name is Jim."