En route to Alpha Malurian Six to settle a dispute between two religions, the U.S.S. Enterprise first stops to do a routine check on the progress of a terraforming colony on Beta Canzandia Three, a colony whose inhabitants include Carol and David Marcus.
Spock is left behind at the terraforming colony to continue his scientific studies and the rest of the crew heads to Alpha Malurian Six to find the dispute has turned to war.
As Kirk, McCoy, and Scotty search for a solution to end the conflict, a ship piloted by a Klingon faction arrives at the terraforming colony to take control of the facility. When colonists are imprisoned, and Spock and David must defeat the Klingons or face certain death.