Development of high-performance membranes for biogas upgrading is an urgent demand for the application of membrane technology in the field of renewable energy. Covalent organic frameworks (COFs) exhibit promising potential in membrane-based separation for their highly ordered crystalline porous structure, total organic backbone and tailored functionality. However, the limited functional groups on frameworks and relatively larger pore size of existing COFs restrict further improvement in the separation efficiency especially for gas mixtures. This work reports a novel strategy for modifying the pore of COF-300 with imidazolium-based ionic liquid [bmim][Tf2N] by post-impregnation and then incorporate the composite particles IL@COF-300 into Pebax matrix to prepare mixed matrix membranes (MMMs). The IL decreases the pore size of COF-300 from 1.28 nm to 1.09 nm and increases the diffusion coefficient difference (DCO2/DCH4) between CO2 and CH4. Moreover, the presence of IL with high CO2 solubility endows the COF-300 pores with CO2-facilitating ability and thus increasing the solubility difference (SCO2/SCH4). The dual functions of IL lead to an enhanced separation performance of the resultant IL@COF-300/Pebax MMMs with an optimal permeability of 1601 Barrer and a CO2/CH4 gas selectivity of ~39, i.e. 209% and 87% higher than the pristine Pebax membrane, respectively, breaking the trade-off between permeability and selectivity and surpassing the Robeson 2008 upper-bound. The membrane also exhibits superior long-term operation stability during two months.