What Foods Cause Gas and How to Reduce It

Beans, dairy, cruciferous vegetables, and sugar-free products are among the most common gas-producing foods. Most intestinal gas comes from bacteria in your large intestine fermenting carbohydrates that your small intestine couldn’t fully break down. Passing gas 14 to 23 times a day is considered normal, so the goal isn’t to eliminate gas entirely but to identify which foods push you past your comfort zone.

How Your Gut Produces Gas

Five gases make up more than 99% of what you pass as flatulence: nitrogen, oxygen, carbon dioxide, hydrogen, and methane. None of these actually smell. The characteristic odor comes from tiny amounts of sulfur-containing gases like hydrogen sulfide, which are produced when gut bacteria break down certain proteins and sulfur compounds in food.

The real gas factory is your colon. When carbohydrates, fibers, or sugars escape digestion in your small intestine, bacteria in your large intestine ferment them and produce hydrogen and methane as byproducts. The more undigested material that reaches your colon, the more gas you produce. This is why the biggest gas offenders are foods rich in complex carbohydrates that resist digestion in the upper gut.

Beans and Legumes

Beans are the most notorious gas-producing food for good reason. They contain raffinose, a complex sugar that humans lack the enzyme to break down. Since your small intestine can’t process raffinose, it passes intact into the colon where bacteria eagerly ferment it, producing a burst of gas. Lentils, chickpeas, and black beans are all high in raffinose.

You can significantly reduce the gas from beans by soaking dried beans in boiling water overnight. Boiling them for two to three minutes before soaking breaks down the cell membranes, releasing the oligosaccharides (the gas-causing sugars) into the water. The key step: discard that soaking water before cooking. Canned beans benefit from a thorough rinse for the same reason.

Cruciferous Vegetables

Broccoli, cabbage, Brussels sprouts, cauliflower, and kale all belong to the cruciferous family, and they share two properties that produce gas. First, they contain raffinose, the same indigestible sugar found in beans. Second, they’re rich in sulfur compounds, which means the gas they produce tends to be more odorous than what you’d get from other plant foods. Asparagus falls into a similar category.

Cooking these vegetables breaks down some of the complex carbohydrates and makes them easier to digest than eating them raw. Steaming or roasting won’t eliminate gas entirely, but it typically reduces it.

Dairy Products

An estimated 65% to 70% of the world’s adult population has some degree of reduced ability to digest lactose, the sugar in milk. The rates vary dramatically by region: only 5% to 15% of people in Northern Europe are affected, compared to 90% to 100% in East Asia. If you’re among them, undigested lactose ferments in your colon and produces gas, bloating, and sometimes cramping or diarrhea.

Milk, ice cream, soft cheeses, and yogurt are the primary culprits. Hard aged cheeses like cheddar and Parmesan contain very little lactose and are usually well tolerated. Many people with mild lactose intolerance can handle small amounts of dairy without trouble but hit a threshold where symptoms kick in.

Wheat and High-FODMAP Foods

FODMAPs are a group of short-chain carbohydrates that your small intestine absorbs poorly. The acronym covers fermentable oligosaccharides, disaccharides, monosaccharides, and polyols, but what matters practically is the list of foods that contain them. Beyond the beans and dairy already mentioned, common high-FODMAP foods include:

  • Wheat-based products: bread, cereal, crackers, and pasta
  • Certain vegetables: onions, garlic, artichokes, and asparagus
  • Certain fruits: apples, pears, cherries, and peaches

These foods don’t cause problems for everyone, but people with irritable bowel syndrome or small intestinal bacterial overgrowth are particularly sensitive to them. If gas is a persistent issue, a low-FODMAP elimination diet (where you remove these foods and reintroduce them one at a time) can help you pinpoint your personal triggers.

Sugar-Free Products and Sugar Alcohols

Sugar-free gum, candy, protein bars, and diet drinks often contain sugar alcohols as sweeteners. Your stomach can’t absorb these compounds, so they linger in your intestines and ferment. The result is gas, bloating, and sometimes diarrhea, often within hours of eating them.

Xylitol is one of the worst offenders. In a study comparing sugar alcohols, participants who consumed xylitol reported bloating, gas, upset stomach, and diarrhea, while erythritol caused milder symptoms and mainly at high doses. Sorbitol and mannitol are problematic enough that the FDA requires products containing them to carry a warning that excessive consumption can have a laxative effect. Check the ingredient list of any “sugar-free” product if you’re dealing with unexplained gas.

Carbonated Drinks

Soda, sparkling water, and beer introduce carbon dioxide directly into your digestive tract. Some of this gas is released through burping, but a portion travels further through the intestines and contributes to bloating and flatulence. Carbonated drinks also promote aerophagia, which is the medical term for swallowing excess air. If you’re already eating gas-producing foods, adding carbonation on top amplifies the effect.

Fiber, Especially When You Add It Quickly

Fiber is essential for digestive health, but it’s also one of the most common causes of increased gas. This is especially true when you ramp up your intake quickly, whether through whole grains, vegetables, or fiber supplements. Your gut bacteria need time to adjust to changes in the amount of fermentable material arriving in your colon.

The Mayo Clinic recommends increasing fiber gradually over a few weeks rather than making a sudden dietary shift. People who start taking fiber supplements like psyllium sometimes experience a spike in gas that fades as their digestive system adapts. Soluble fiber (found in oats, beans, and fruits) tends to produce more gas than insoluble fiber (found in wheat bran and many vegetables) because it dissolves in water and is more readily fermented by gut bacteria.

Why Some People Are More Affected

Two people can eat the same meal and have very different gas responses. The composition of your gut microbiome plays a major role. Someone whose colon bacteria produce more methane will have different symptoms than someone whose bacteria favor hydrogen production. Your enzyme levels matter too: people with higher natural levels of the enzymes that break down raffinose or lactose will tolerate beans and dairy far better than those without.

Speed of eating also matters. Eating quickly, talking while you chew, or drinking through a straw increases the amount of air you swallow. That swallowed air accounts for a portion of intestinal gas that has nothing to do with what you ate. Slowing down at meals can make a noticeable difference, particularly if you’re combining fast eating with gas-producing foods.

Practical Ways to Reduce Gas

Rather than cutting out every potential trigger, a more effective approach is to identify your specific problem foods. Keep a simple food diary for a week or two, noting what you eat and when gas becomes bothersome. Patterns usually emerge quickly.

Once you’ve identified likely culprits, these strategies help:

  • Soak dried beans overnight in boiling water and discard the soaking liquid before cooking
  • Cook cruciferous vegetables rather than eating them raw
  • Increase fiber slowly over two to three weeks to give your gut bacteria time to adjust
  • Check labels for sugar alcohols like sorbitol, xylitol, and mannitol in sugar-free products
  • Swap carbonated drinks for still water or non-carbonated beverages
  • Eat more slowly and avoid talking with your mouth full to reduce swallowed air

If you’re consistently passing gas more than 23 times a day or experiencing pain, significant bloating, or changes in your bowel habits alongside the gas, something beyond normal food fermentation may be going on. Conditions like lactose intolerance, irritable bowel syndrome, and small intestinal bacterial overgrowth all have gas as a primary symptom and respond well to targeted dietary changes.