HDACs function by catalyzing the removal of acetyl groups from lysine residues on histone proteins. This deacetylation process leads to a more compact and transcriptionally silent chromatin structure. HDACs are often found in complexes with other proteins that help in targeting specific regions of the genome, thereby providing a mechanism for dynamic and reversible control of gene expression.