Covalent organic framework (COF) aerogels with functional groups offer exceptional processability and functionality for various applications. These hierarchical porous materials combine the advantages of COFs with the benefits of aerogels, overcoming the limitations of conventional insoluble and nonfusible COF powders. However, achieving both high crystallinity and shape retention remains a challenge for functionalized COF aerogels. In this work, we develop a novel and general solvent substitution method for the one-step synthesis of formylfunctionalized COF aerogels without harsh vacuum conditions. These aerogels exhibit excellent processing capabilities, superior mechanical strength, and enhanced functionality. As a proof-of-concept, they were used in adsorption and lithium metal battery applications, significantly maximizing the structural advantages of COFs, e.g.: (i) the hierarchical porous structure is fully wetted by the electrolyte to form continuous transport channels; (ii) the polar groups, which are easier to be acquired, help in desolvation and transfer of Li + ; (iii) the regular pore structures stabilize deposition of Li + and inhibit the growth of lithium dendrites. These combined benefits contribute to a lighter battery with improved energy density and enhanced safety.