Thermoplastic polyimide foams are provided which essentially consist of recurring units represented by the formula (I): (I) (wherein X is a bond, divalent hydrocarbon radical having from 1 to 10 carbon atoms etc. and R is an aliphatic radical having 2 or more carbon atoms, cycloaliphatic radical etc.). The foams have an apparent density of from 0.02 to 0.2 g/cc and preferably an average cell diameter of 0.1 to 1 mm and a closed cell content of 50% or more.