A mild and safe chloromethylation of metal–organic frameworks is presented. After this post-synthetic functionalization, chlorine can be substituted by a wide range of moieties to obtain various multifunctional materials. The method can in principle be extended to coordination polymers with exposed aromatic ring