Protection of carbonyl groups
An aldehyde or ketone is protected as an acetal, dithioacetal or hydrazone. This removes the electrophilicity of the carbonyl carbon and, to a large extent, the acidity of the α hydrogens.
Acetals are formed with an alcohol or diol and an acid catalyst, removing the water (with a Dean–Stark trap or with trimethyl orthoformate). Cyclic ones, 1,3-dioxolanes (with ethylene glycol) and 1,3-dioxanes (with propane-1,3-diol), are more stable than dimethyl acetals. They resist bases, organometallics, hydrides and oxidants, and are hydrolysed by aqueous acid. Review acetals in Organic Chemistry made transparent.

Aldehydes form acetals faster than ketones, and unhindered ketones faster than hindered ones: with one equivalent of diol, one carbonyl group can be selectively protected among several. In the example, the ketone of methyl levulinate is protected so that LiAlH4 reduces only the ester; without protection, both groups would be reduced.
Dithioacetals (1,3-dithianes and 1,3-dithiolanes) are formed with dithiols and Lewis acids and are stable even in aqueous acid; they are removed with mercury(II) salts, hypervalent iodine or alkylating agents and also allow the umpolung of aldehydes or desulfurization with Raney nickel, which turns C=O into CH2. N,N-Dimethylhydrazones protect the carbonyl and, at the same time, serve to alkylate the α carbon; they are hydrolysed oxidatively or with copper(II) salts.