While surveying land on a Federation colony known as Melona IV, Riker, Data and Dr. Crusher are suddenly interrupted by the appearance of a massive, crystal-like structure which begins to descend toward the planet. Riker recognizes the object as the Crystalline Entity, and immediately begins herding the colonists together to search for shelter. The group watches in horror as the entity destroys the countryside with brilliant beams of light. All but two survive to find shelter inside a small cave — but the cave has a limited air supply. Riker tries to contact the U.S.S. Enterprise, but ultimately fails. Meanwhile, on board the Enterprise, the rest of the crew grow increasingly concerned over the violent disturbances detected near Melona IV.

Just as Beverly insists that the cave be opened to let in more air, Worf appears at the entrance, much to everyone's relief. The crew and colonists are transported back to the U.S.S. Enterprise, where they are greeted by scientist Kila Marr, who has spent her life studying the Crystalline Entity. Picard suggests that Data aid Marr in her investigation. Marr, however, opposes the idea, reminding Picard that Data's brother Lore lured the Crystalline Entity to the planet Omicron Theta where it ruthlessly killed every living thing. Picard, however, insists on Data's inclusion. Later, when the unhappy partners begin their investigation on Melona IV, Marr accuses Data of collaborating with the Entity as his brother did. She also tells Data that her son was among those killed on Omicron Theta.

Back on board the U.S.S. Enterprise, Marr begins to relax as Data uncovers information that is invaluable to their investigation. However, she becomes even more upset when she learns that Picard intends not to destroy the Entity, but to communicate with it. Later, knowing that Data carries specific information regarding the events on Omicron Theta, Marr asks him to access her son's daily journals. Through Data, she learns her son did not blame her for the disaster on the planet. Her joy, however, is interrupted by a distress call from a ship being pursued by the Crystalline Entity.

The crew sets a course for the ship and discovers that there are no survivors. At this point even Riker wonders if perhaps the Entity should be destroyed, but Picard does not flinch. Meanwhile, Data keeps up his desperate attempts to communicate with the Entity before it kills again.

The crew manages to lure the Entity toward the ship, and the being seems to respond to their attempts to reach it. But at the same time, Marr begins trying to destroy it by sending harmful transmissions. Although the crew notices a change in the Entity and realizes what Dr. Marr is doing, they are ultimately unable to save the Entity. The being explodes into space, leaving Dr. Marr to wonder if revenge was worth the price of her career as a scientist.