Fruits and vegetables are unquestionably essential to a healthful diet.

But there’s another side to some of these plants that, thankfully, most people never see: the tiny amounts of toxins within them. The minute amounts of poison found in many seeds, leaves, and roots, are the result of the protracted arms race between plants and the animals that try to eat them. It’s the reason why you’ve never shelled a cashew (the shells might make you break out in a poison ivy-style rash) or eaten green potato fries (read on for details).

Most of the time, the human body manages to dispose of the toxins with minimal effort. But every now and then, an edible plant can be a problem.

The recently revisited case of Christopher McCandless, the subject of Jon Krakauer’s bestseller Into the Wild, reminded us of this plant duality. In 1992, McCandless was found dead in the Alaskan wilderness. Because he had so little fat left on his body, the coroner concluded that he’d died of starvation.

But the 24-year-old may have died from eating the seeds of the wild potato (Hedysarum alpinum), an edible plant. As Krakauer explained on All Things Considered last month, the plant’s seeds contain a neurotoxin that is harmless to healthy people but can cause paralysis in a nutrient-starved body like that of McCandless, who was already lean and weak from months of trying to live off the land.

Turns out, people eat plants like that all the time. Over the centuries, humans have come to recognize the dangerous side of these dinner options, and have often found safe preparation methods to get around them. Odds are, you’ve eaten them before without a second thought. Here’s a look at just a few commonly eaten plants that can sometimes turn their defenses on us:

Paralysis Pea: Because it’s almost drought resistant, the hardy grass pea (Lathyrus sativus) is grown regularly as a safety crop by subsistence farmers in places like India and Ethiopia. But the protein-rich seed contains the same toxin, β-ODAP, found in the wild potato that McCandless ate.

It’s harmless in small quantities, especially if it’s been soaked in water for a long time. But a steady diet of grass pea seeds over a three-month period can cause a neurological disorder called lathyrism. That’s what Jewish inmates of one Ukrainian concentration camp experienced in 1942. The camp’s Nazi officers provided inmates with flour made from grass pea seeds. It was death by bread. Within months, many became paralyzed in the lower body. Like Chris McCandless, the inmates were malnourished and physically exhausted.

How much is too much? Generally, in order to develop lathyrism, someone would have to eat grass peas for two or three months, and the plant would have to compose at least a third of the total dietary intake. But there is wide variation in how much of the toxin one grass pea seed contains, and also in how people are affected.

The sprouts on a potato contain solanine. The rest of the potato can, too — especially if it’s green. The exposure to light and heat that produce the color also help produce the toxin. Illustration: Rae Ellen Bichell/NPR

The Mean Green Solanine Machine: There are good reasons why the FDA tells consumers not to eat green potatoes.

Potatoes are related to deadly nightshade. While a white, brown, or even Peruvian purple potato is fine to eat, the green patches and sprouting stems on a tater are not. The green color comes from chlorophyll, and indicates that the plant has been exposed to enough light and heat to get enzymes kicking that lead to the production of two toxic chemicals, solanine and chaconine. Cooking doesn’t get rid of them: Excessive heat will kill the enzyme that produces solanine, but not the toxins themselves.

In 1924, James B. Matheney of Vandalia, Ill., had gathered about 80 to 90 pounds of potatoes to feed his family, not realizing that many of them had turned green from being left out in the sun. A week later, his wife and daughter died. A 1925 issue of Science magazine reported on the “two fatal cases of potato poisoning.”

How much is too much? An average person would probably have to eat about two pounds of fully green potato to get sick.

Cook-Well-For-Survival Cassava: Cassava (Manihot esculenta) is a major root crop for millions of subsistence farmers in sub-Saharan Africa. According to the FAO, after rice and maize, it’s the third most important source of calories for people living in the tropics. But wild species can contain lethal levels of toxins.

Cassava leaves make a chemical called linamarin, which meanders down to the roots, where it produces toxic hydrocyanic acid, or cyanide, when the root cells rupture. In the human body, linamarin can come in one end and go out the other intact, but if it gets broken down during digestion and runs into the enzyme linamarase, it will produce cyanide in the gut.

Counterintuitively, the key to cooking cassava safely is to encourage the cyanide to form, often by grating it into little bits, and then soaking, fermenting, and evaporating the bad stuff out before cooking thoroughly.

Sweet cassava roots usually contain less cyanogen than bitter ones, so they require less preparation — just peeling and thorough cooking tends to be enough. For the more toxic breeds of cassava, preparation can take days. If it’s done wrong, things can go badly, as it did with three people who died in Nigeria in 1992 after eating a cassava tapioca. More commonly, repeatedly eating poorly processed cassava can cause a neuron disorder called Konzo.

How much is too much? Most cassava tubers can produce between 15 and 400 mg of hydrogen cyanide per kilogram. In the short term, the human body is good at filtering out cyanide. But research has shown that chronic ingestion of cooked cassava can, over many years, cause cyanide accumulation in blood plasma. And it’s best not to munch on the raw root.

The toadstools have a chemical in them that produces a toxic compound called monomethylhydrazine, or MMH. If you’re trying to launch a rocket into space, MMH is really useful — NASA likes to put it in its rocket fuel because it ignites spontaneously when it runs into other propellant ingredients. In the body, the known carcinogen can interfere with neurotransmitters, and can render the eater comatose.

Spain prohibits the sale ofthesemushrooms for this reason, but Nordic folk go wild over false morel soup, which is also a delicacy in Eastern Europe and the Great Lakes region of North America. Chefs parboil the mushrooms repeatedly, pouring off the water each time to get rid of the poison.

How much is too much? MMH is a cumulative toxin — its levels build up in the body after repeated consumption — so it’s hard to determine a lethal amount. There’s a saying among mycologists: “There are old mushroom hunters, and there are bold mushroom hunters, but there are no old, bold mushroom hunters.”

A Lethal Leaf: Oxalic acid is great for removing paint, bleaching fabrics and sanitizing toilet bowls. The acid also lurks in the leaves of rhubarb (Rheum rhaponticum), the stalks of which often get paired with strawberry for a delicious pie.

The stalks are all good, but steer clear of the leaves: The oxalic acid in them leaches calcium from the blood. As rumor goes, the Brits realized this during World War I, when food shortages got people to be creative with recipes.Across the pond at about the same time, the Journal of the American Medical Association reported a sad case in 1919 of a “Mrs. A” in Montana, who ate a lot of fried rhubarb leaves and died the next day, after a horrible miscarriage and unstoppable nosebleeds and vomiting.

How much is too much? Oxalic acid content ranges wildly, and can depend on factors like the air temperature outside. Your best bet: Just don’t eat those leaves! To treat animals that have eaten them, veterinarians can use chalk to neutralize the acid, a trick that’s also suggested in a few rare recipes for human consumption.

Thanks to Amy Stewart, author of “Wicked Plants,” “Wildman” Steve Brill, creator of the “Wild Edibles” app, and Dr. Ruth Lawrence of the University of Rochester Medical Center for their input and guidance in putting this list together.