Why do people seek out information about an ex's new relationships, read negative Internet comments and do other things that will obviously be painful? Because humans have an inherent need to resolve uncertainty, according to a recent study in Psychological Science. The new research reveals that the need to know is so strong that people will seek to slake their curiosity even when it is clear the answer will hurt.

In a series of four experiments, behavioral scientists at the University of Chicago Booth School of Business and the Wisconsin School of Business tested students' willingness to expose themselves to aversive stimuli in an effort to satisfy curiosity. For one trial, each participant was shown a pile of pens that the researcher claimed were from a previous experiment. The twist? Half of the pens would deliver an electric shock when clicked.

Twenty-seven students were told which pens were rigged; another 27 were told only that some were electrified. When left alone in the room, the students who did not know which ones would shock them clicked more pens and incurred more jolts than the students who knew what would happen. Subsequent experiments replicated this effect with other stimuli, such as the sound of fingernails on a chalkboard and photographs of repulsive insects.

The drive to discover is deeply ingrained in humans, on par with the basic drives for food or sex, says Christopher Hsee of the University of Chicago, a co-author of the paper. Curiosity is often considered a good instinct—it can lead to new scientific advances, for instance—but sometimes such inquiry can backfire. “The insight that curiosity can drive you to do self-destructive things is a profound one,” says George Loewenstein, a professor of economics and psychology at Carnegie Mellon University who has pioneered the scientific study of curiosity.

Morbid curiosity is possible to resist, however. In a final experiment, participants who were encouraged to predict how they would feel after viewing an unpleasant picture were less likely to choose to see such an image. These results suggest that imagining the outcome of following through on one's curiosity ahead of time can help determine whether it is worth the endeavor. “Thinking about long-term consequences is key to mitigating the possible negative effects of curiosity,” Hsee says. In other words, don't read online comments.