"The Apple" is the fifth episode of the second season of the American science fiction television series Star Trek. Written by Max Ehrlich and directed by Joseph Pevney, it was first broadcast on October 13, 1967.
 In the episode, the crew of the Enterprise visits a planet whose inhabitants live only to serve a machine.
 The USS Enterprise arrives at Gamma Trianguli VI, a planet appearing to be a tropical paradise with very rich natural resources. Captain Kirk leads a landing party including Chief Medical Officer Dr. McCoy, Ensign Chekov, First Officer Spock, Yeoman Martha Landon, and four security personnel. They quickly find the "paradise" is extremely hostile, losing three of the security team to a plant that shoots poisonous thorns, a bizarre lightning storm, and an explosive rock. Transporting back to the ship is impossible, as an energy field is drawing power from the Enterprise, rendering the transporters inoperable.
 Kirk orders the team towards a primitive village, carefully avoiding hazards. Along the way, they capture a native of the planet who has been tracking them. The frightened man, Akuta (Keith Andes), says he is the chief of the "Feeders of Vaal". Small antennae on his head allow him to communicate with "Vaal", acting as the entity's eyes and ears. During this conversation, Chief Engineer Scott reports that the Enterprise is slowly being pulled towards the planet by a tractor beam. Kirk, suspecting a connection with Vaal, asks Akuta to take them to it. 
 Akuta leads them to a rock formation with a dragon-like head figure in front. Spock's analysis shows the entrance is protected by a force field, but appears to lead to an underground complex. Akuta says that Vaal may wish to speak with them later, but in the meantime, offers the hospitality of his village.
 The Enterprise crew find the villagers to be young and healthy, like Akuta, but somewhat unsophisticated. The villagers say Vaal prohibits "touching", as "replacements" (children) are not needed. After a while the villagers are observed "feeding" Vaal with the explosive mineral, apparently its fuel, and the landing party conclude that Vaal is a machine which maintains the planet's Eden-like conditions, making the inhabitants virtually immortal and rendering most work unnecessary. Spock and McCoy argue over the desirability of this system, but Kirk reminds them they need to free the Enterprise.
 In the evening, Chekov and Landon go to a secluded area to kiss, and a young native couple observe and copy their behavior. Vaal is instantly aware, and through Akuta, orders the natives to kill the strangers in the morning. During their attack the last security man is killed, but the rest of the crew subdue the villagers and place them in a hut. Landon in particular distinguishes herself in the fight, using impressive hand-to-hand combat skills to disable two villagers. 
 Scott reports that an attempt using all available power to free the ship has failed. Kirk orders his crew to prevent the villagers from feeding Vaal, and instructs Scott to fire the ship's phasers on the rock formation, hoping to drain Vaal's remaining power. Vaal is overloaded and the Enterprise is freed from the tractor beam. 
 Kirk tells a distraught Akuta that his people will now be able to experience normal life. Aboard the ship, Spock suggests that their actions were the equivalent of the fruit of the Tree of Knowledge - driving the villagers from their Garden of Eden. Kirk wryly rejoins that maybe another member of the crew looks more like Satan than Kirk does.
 The episode guest stars a young David Soul (of Starsky & Hutch fame) as one of the Feeders of Vaal.
 The episode makes the only TOS in-series reference to the saucer section being able to separate from the rest of the Enterprise when Kirk is discussing options for Scotty to save the ship.
 Zack Handlen of the A.V. Club gave the episode a "B−" criticizing Kirk's interference in the planet's culture.
 In 2009, GameRadar+ noted this episode for death of crewman Hendorff (actor Mal Friedman) by a deadly plant during the away mission to the planet's surface.
 In 2017, Den of Geek ranked "The Apple" the ninth worst episode of the original Star Trek television series.