Marsh gas, also known as swamp gas or bog gas, is a mixture primarily of methane and smaller amounts of hydrogen sulfide, carbon dioxide, and trace phosphine that is produced naturally within some geographical marshes, swamps, and bogs.
The surface of marshes, swamps, and bogs is initially porous vegetation that rots to form a crust that prevents oxygen from reaching the organic material trapped below. That is the condition that allows anaerobic digestion and fermentation of any plant or animal matter, which then produces methane.
The trapped methane can escape through any of three main pathways: by the diffusion of methane molecules across an air–water interface, by bubbling out of water in a process known as ebullition, or through plant-mediated transport.[1]