The corrosion-resistant and heat-resistant electromagnetic shielding foams were fabricated by multi-walled carbon nanotube/poly ether ether ketone/thermoplastic polyimide (MWCNTs/PEEK/TPI) composites with double percolation structure. MWCNTs/PEEK/TPI foams based on double percolation structure were obtained by introducing the cell into MWCNTs/PEEK/TPI composites using near-melting point saturated supercritical carbon dioxide (Sc-CO2) foaming technology. The appearance of cell structure further reduced the conductivity and the electromagnetic shielding percolation thresholds of MWCNTs/PEEK/TPI foam to 0.03989 vol% and 0.05552 vol% respectively, which were 89.58% and 91.33% lower than those of MWCNTs/PEEK/TPI composite. By contrast, it was found that the total electromagnetic shield value (SETotal) and specific total electromagnetic shield value (SSETotal) of 0.6313 vol%-MWCNTs/PEEK/TPI foam (0.1894 g/cm3) were 26.09% and 795.6% higher than that of 0.6404 vol%-MWCNTs/PEEK/TPI composite (1.3449 g/cm3). The introduction of the cell led to a transformation from reflective to absorptive electromagnetic shielding materials. The MWCNTs/PEEK/TPI foam could withstand various chemical corrosion and high temperature of 300 °C for a long time, which was suitable for extreme environmental service.