Double-layered zeolitic imidazolate framework (ZIF) membranes were fabricated inside polyimide P84 hollow fibers by a step-synthesis conducted by microfluidic technology and applied to pre-combustion gas separation. Our hypothesis, based on the information provided by a combination of molecular simulation and experiments, is that a CO2 adsorption reduction on the surface of the ZIF-9 would enhance the molecular sieving effect of this ZIF-9 layer and therefore the selectivity in the H2/CO2 mixture separation of the entire membrane. This reduction would be achieved by means of a less-CO2-adsorptive methylimidazolate-based ZIF-67 or ZIF-8 layer coating the ZIF-9. ZIF-8/ZIF-9 and ZIF-67/ZIF-9 double-layered membranes were prepared and characterized by XRD, FTIR, SEM, FIB, TEM and EDS. This unprecedented strategy led to a H2/CO2 separation selectivity of 9.6 together with a 250 GPU H2 permeance at 150 °C, showing a significant improvement with respect to the pure ZIF-9 membrane. Double-layered membranes also showed higher apparent CO2 activation energies than single-layered membranes, attributable to a diminished adsorption.