In the recovery of methane and carbon dioxide from landfill gas (LFG) a selective adsorption system is employed having a pretreat section operated in temperature swing adsorption mode (TSA) to remove water and trace hydrocarbon contaminants, in flow communication with a pressure swing adsorption section (PSA) for separation of the methane from CO.sub.2 contained in the purified gas stream discharged from the pretreat section. The LFG is introduced into a column in the TSA section and passed consecutively through a layer of activated carbon followed by a layer of solid desiccant such as a molecular sieve zeolite. The activated carbon layer adsorbs trace contaminants such as hydrocarbons and halohydrocabons boiling above methane; the zeolite layer adsorbs water. Regeneration of the adsorbent layers is carried out by flowing hot regeneration gas first through the zeolite layer then into and through the carbon layer. When the zeolite layer has been heated to the highest regeneration temperature by the regeneration gas, the inlet temperature of the gas is lowered by 100 or more degrees (.degree.F), so that the carbon layer is regenerated at a lower temperature level to avoid detriment to the activated carbon adsorbent that might otherwise occur.