Aerogels have been widely used in the fields like thermal insulation, energy storage, environmental remediation, catalysis, drug release, sensor, and cosmic dust collection, etc. Hydrophobic functionalization not only determines the surface energy and basic physical properties of the target aerogels but also be critical for their long-term stability due to their highly open-porous structures. However, there is still lack of facial and versatile methodologies for the hydrophobic functionalization of aerogels, especially for the nonsilica ones. Herein, two efficient fluorine-free strategies were developed to synthesize various hydrophobic and even superhydrophobic polyimide (PI) aerogels. First, superhydrophobic PI aerogels with contact angle higher than 150° were fabricated by the segregation self-assembly process between poly[4,4'-(4,4'-isopropylidenediphenoxy)bis(phthalic anhydride)- co- p-phenylene diamine] and poly[biphenyl-3,3',3,4'-tetracarboxylic dianhydride- co-2,2'-dimethylbenzidine] (poly(BPDA-DMBZ)). These PI aerogels exhibited a lotus effect that water droplets could not wet the surface but could easily roll off. Second, various hydrophobic PI aerogels, including the well-documented superhydrophilic PI aerogels derived from DMBZ-BPDA and 4,4'-oxydianiline-BPDA, were synthesized by the density-induced hydrophilicity-hydrophobicity transition approach. These PI aerogels exhibited a petal effect that water droplets on the aerogel surface appeared spherical in shape, which could not roll off even when the aerogel was turned upside down. These two reported strategies might open new and straightforward ways to hydrophobic functionalization of other polymeric aerogel systems.