The Enterprise investigates a T Tauri class star system with a single Class M planet that was picked up on a long-range sensor scan near the Ngame Nebula. As they approach the planet, the ship encounters a wormhole and everyone except Lt. Commander Data briefly loses consciousness.
When the crew awakens, Data informs Captain Jean-Luc Picard that they were unconscious for 30 seconds; however, the ship's first officer, Commander William Riker, notices that navigational readouts indicate a much longer period of travel, perhaps an entire day. Data quickly explains that the helm instrumentation may have been thrown off by the wormhole, and adds that wormholes are quite common in T-Tauri type systems. He advises that the ship not return to the area, due to the danger of the wormhole, and recommends that a probe be launched instead. Picard follows his advice but, as the probe approaches the system, its sensors indicate a frozen gas giant, not the class M planet indicated by the original long-range scan. Again, Data offers the explanation that the planet seemed to be M-class because of the effect of the wormhole, and Picard accepts this.
However, the Enterprise's chief medical officer, Dr. Beverly Crusher, soon comes to the captain with an odd and unusual puzzle: It seems that some Diomedian scarlet moss she was growing in the science lab grew much more than it should have given the short period of time it had supposedly incubated. Next, the ship's chief of security, Lt. Worf, shows up in sick bay with a sore wrist, and Crusher is stunned to find that it has been recently broken and expertly reset by a medical professional; Worf has no memory of the injury. Realizing that the Enterprise seems to be suffering from a missing time syndrome, Picard begins to suspect that Data might be lying.
When Picard confronts Data with these inconsistencies, the android cannot offer a credible explanation. Now openly suspicious, Picard dismisses him from the room and orders an investigation. Beverly quickly finds out that cellular scans show their bodies have aged far too long for Data's story to be true, indicating that the crew was unconscious or has no memory for a period of at least several hours, not 30 seconds. Chief Engineer Geordi La Forge then discovers that the ship's chronometer has been tampered with, a feat only he or Data could have accomplished. At this point Picard has no other choice but to accept that Data is covering up the truth, so he orders Geordi to examine Data.
After failing to find anything out of order with Data, Geordi then analyzes the data from the probe Data launched. He discovers that the sensor readings returned by the probe have been tampered with, and the visual record of the planet was replaced by one from the Federation database that has been altered to make it unrecognizable. Meanwhile, Counselor Deanna Troi becomes terrified when she returns to her cabin after going off duty and gets the feeling that someone else is looking back at her from her own eyes in the mirror.
Picard gets angry when Data answers "I cannot say...My silence is not by choice" to any inquiries and appears to prefer being court-martialed and dismantled rather than reveal the truth. Picards starts to suspect that Data thinks he is protecting Enterprise by his silence. Picard decides to return to the mysterious planet in an attempt to get some answers. Upon arrival, they see a class M planet and a green energy field, which emits a pulse, which penetrates shields and gains control of Deanna Troi. She tells Data with a strange alien voice: "Your plan has failed, your ship is again in our space".
Picard calls for Data and questions him again, and is shocked when Data says that he was ordered by Picard to conceal the truth. The planet is inhabited by the Paxans, aliens who are rabidly xenophobic and possess very advanced technology. To prevent being discovered by other races, they stun the crew of any near-passing ship and move the ship away in such a way that the crew believes it encountered a wormhole.
When the Enterprise first approached the planet, the Paxans tried the same but Data was immune to Paxan stun field and revived the crew. Paxan gained control of Deanna, who broke Worf's wrist in an ensuing fight. Paxans wanted to destroy the Enterprise to protect their privacy but Picard came to agreement with them that they would instead erase crew's memories of this event. Picard then ordered Data never to disclose the existence of Paxans.
Now, seeing that the plan failed, Paxans announce through Deanna they intend to destroy Enterprise again, but Picard convinces them to try the original plan one more time, explaining that humans are curious by nature, and unable to resist solving a puzzle. He says that the first attempt failed because too many clues were left, creating a mystery which the crew wanted to solve. The Paxans agree and this time the whole crew intensively works to remove any clues
Once again Data is ordered to silence, the crew's memories are erased, and the ship is moved far from the planet. This time, when the crew awakens, they accept Data's explanation of what apparently happened without question and, after a tentative pause by Picard, continue their mission without suspecting the truth.