For tobacco hornworms, bad breath might be the key to surviving the night. As their name suggests, these desert-dwelling caterpillars (larvae of the Manduca sexta moth) regularly chomp on nicotine-laced tobacco leaves. Scientists observed that caterpillars feeding on genetically modified, nicotine-free tobacco plants were more likely to disappear during the night than those chowing down on regular tobacco, leading them to suspect that the hornworms might be repurposing the toxic chemical to defend themselves against nocturnal predators like wolf spiders (Camptocosa parallela, pictured above feasting on a larva). The researchers investigated a gene called CYP6B46, which is active in the hornworm’s gut. Turning the gene off resulted in higher nicotine levels in the hornworms’ poop, suggesting that the gene helps the larvae avoid excreting the chemical by pumping it out of their guts and into their blood. The caterpillars had to be exuding the toxic nicotine somehow, so the scientists gave them an insect version of a breathalyzer test and discovered that they breathe it out with every exhale, the team reports online today in the Proceedings of the National Academy of Sciences. This “toxic halitosis” repelled wolf spiders, which actually flee from caterpillars with nicotine on their breath, as you can see in this video. Still, bad breath is no guarantee of a long life: It didn’t deter some of the hornworms’ other predators, including big-eyed bugs and antlion larvae.