Alkali metal compounds have vital influence on biomass pyrolysis conversion. In this study, cellulose, and bamboo catalytic pyrolysis with different alkali metal salts catalysts (KCl, K2SO4, K2CO3, NaCl, Na2SO4, and Na2CO3) were investigated in the fixed-bed reaction system. The effects of cations (K+ and Na+) and anions (Cl-, SO42−, and CO32-) on the evolution properties of biochar, bio-oil, and gas products were explored under both in-situ and ex-situ catalytic pyrolysis. Results showed that alkali metal salts facilitated the yields of biochar and gases at the expense of that of bio-oil. Alkali metal chloride and sulfate showed a weaker catalytic effect, while alkali metal carbonate greatly promoted the generation of gas products and increased the condensation degree of biochar. With the addition of K2CO3 and Na2CO3, cyclopentanones content was over 50% from cellulose catalytic pyrolysis, and phenols content (mainly alkylphenols) reached over 80% from bamboo catalytic pyrolysis. Moreover, solid-solid catalytic reactions with K2CO3 and Na2CO3 catalysts had an important role in strikingly promoting conversion of pyrolysis products, and the solid-solid and gas-solid catalytic reactions with alkali metal carbonate catalysts were stronger than those with alkali metal chloride and sulfate catalysts. Furthermore, the possible catalytic pyrolysis mechanism of alkali metal salts on biomass pyrolysis was proposed, which is important to the high-value utilization of biomass.