Food allergies: what are tree nuts?

Which nuts are actually tree nuts, how they differ from peanuts and coconuts, and where they secretly hide in everyday meals.

Wooden tray of assorted tree nuts — walnuts, almonds, cashews, pecans, pistachios, hazelnuts, and macadamia nuts — on a bright kitchen counter

If you or a family member has recently been diagnosed with a tree nut allergy, navigating ingredient labels can suddenly feel like learning a foreign language. Tree nuts are among the most common food allergens worldwide, and because they appear in everything from savory pestos to commercial bakery items and plant-based milks, avoiding them requires vigilance.

To make matters more confusing, culinary language doesn't always match botanical science. Is a peanut a tree nut? Is a coconut safe to eat? What about nutmeg?

This guide breaks down everything you need to know about tree nuts, how to distinguish them from other foods, and where they secretly hide in everyday meals.

What exactly is a tree nut?

From a medical standpoint, a tree nut is any hard-shelled fruit or seed produced by a tree. Tree nut allergies represent one of the "Top 9" major allergens designated by the FDA, and unlike some childhood allergies, tree nut allergies are rarely outgrown — often persisting for a lifetime.

The most common culinary tree nuts

While dozens of plants produce edible tree seeds, the vast majority of food allergy reactions are caused by these common tree nuts:

  • Almonds: Widely used in baked goods, snack mixes, granolas, and as a popular dairy alternative (almond milk, almond flour, and almond butter).
  • Walnuts: Common in baked desserts, salads, pestos, and artisan breads.
  • Cashews: Frequently used as a creamy, blended base for vegan cheeses, cream sauces, and Indian curries, as well as in stir-fries.
  • Pecans: A staple in sweet pies, pralines, stuffing mixes, and salad toppings.
  • Pistachios: Found in ice creams, gelatos, Mediterranean pastries (like baklava), charcuterie spreads, and pestos.
  • Hazelnuts (Filberts): Famous for their heavy presence in chocolate-hazelnut spreads, coffees, pralines, and European confectioneries.
  • Macadamia nuts: Highly prevalent in cookies, tropical baked goods, and specialty nut oils.
  • Brazil nuts & pine nuts (pignoli): Brazil nuts are common in mixed nut tins, while pine nuts are a foundational ingredient in traditional Italian green pestos and Mediterranean grain dishes.

💡 Cross-reactivity warning: Proteins in certain tree nuts are structurally very similar. For instance, individuals allergic to cashews are very likely to also react to pistachios, while those allergic to walnuts frequently react to pecans. Always consult an allergist before assuming one tree nut is safe.

Clearing up the confusion: peanuts, coconuts, and other tricky names

One of the biggest sources of anxiety for newly diagnosed families is figuring out what actually counts as a tree nut.

1. Are peanuts tree nuts?

No, peanuts are not tree nuts.

Botanically speaking, peanuts are legumes (belonging to the same plant family as beans, lentils, and peas) that grow underground. Tree nuts grow above ground on trees.

While someone can certainly be allergic to both peanuts and tree nuts, a peanut allergy does not automatically mean you are allergic to tree nuts. However, peanuts are frequently processed on the exact same equipment as tree nuts in manufacturing facilities, making cross-contamination a significant concern.

2. Is coconut a tree nut?

This is where medical science and federal labeling laws collide.

Botanically, a coconut is a drupe (a single-seeded stone fruit), not a tree nut. Most people with tree nut allergies can safely consume coconut without any issue.

However, the U.S. Food and Drug Administration (FDA) technically classifies coconut as a tree nut on packaged food labels. Because of this legal classification, you will often see coconut listed under tree nut allergen warnings in the United States. If you have a tree nut allergy, ask your allergist specifically whether coconut is safe for you.

3. What about nutmeg, water chestnuts, and butternut squash?

Despite having "nut" in their names, none of the following are tree nuts, and they are generally safe for individuals with tree nut allergies:

  • Nutmeg: A spice derived from the seed of a tropical tree.
  • Water chestnuts: An aquatic root vegetable grown in marshes.
  • Butternut squash: A winter squash (vegetable).
  • Shea nuts: While derived from a nut, refined shea butter used in cosmetics and food contains virtually no allergenic protein and is considered low-risk by food safety authorities.

Hidden places tree nuts lurk

You expect to find tree nuts in a jar of mixed nuts or a chocolate turtle candy, but tree nut proteins frequently hide in less obvious products as thickeners, flavor enhancers, or crusts:

  • Pestos & pasta sauces: Pine nuts or walnuts are standard in green pestos, but cashews are often used in cheaper commercial brands to add bulk.
  • Barbecue sauces & marinades: Some specialty brown sauces and glazes use walnut or pecan flavoring to add a smoky, rich profile.
  • Vegetarian & vegan meat alternatives: Cashews and walnuts are frequently blended into plant-based burger patties, sausages, and vegan cheeses to replicate texture.
  • Artisan beers & flavored liquors: Certain craft beers, bitters, and liqueurs (like Amaretto, Nocino, or Frangelico) use tree nuts during the brewing or distillation process.
  • Mortadella & specialty meats: Traditional Italian mortadella often contains whole pistachios embedded in the meat.

🛡️ Take the guesswork out of tree nut safety.

Trying to memorize every botanical variation and hidden derivative can be exhausting. You shouldn't have to spend your grocery trip or restaurant outing constantly second-guessing ingredient labels.

Let Stuff I Can Eat automate your allergen checks for you. With your free profile, you can instantly screen for tree nuts across your entire day:

  • Scan packaged grocery labels: Snap a photo of any ingredient panel to instantly detect hidden tree nuts, derivative aliases, and precautionary cross-contamination warnings.
  • Filter restaurant menus: Upload or paste any menu to flag high-risk pestos, crusts, or bakery items before you place your order.
  • Flash a digital chef card: Display a bold, full-screen digital allergy card directly on your phone to give kitchen staff clear, explicit boundaries regarding tree nuts and shared prep equipment.

Stop guessing at the menu. Protect your plate today.

Keep reading

More practical guides to help you eat safely and confidently.