The Gattermann reaction is a method for preparing aromatic aldehydes from activated aromatic compounds using hydrogen cyanide (HCN) and hydrogen chloride (HCl) in the presence of a Lewis acid catalyst such as AlCl3 and ZnCl₂:

To understand how the reaction occurs, we first need to realize that the nitrile group is similar to the carbonyl group in that both contain an electrophilic carbon atom. In the carbonyl group, this is due to the electron-withdrawing nature of oxygen, and in the nitrile group, it is the nitrogen that makes the carbon electrophilic.

Remember how the Friedel-Crafts acylation worked – in the first step, we have activation of the carbonyl compound by a Lewis acid, which makes the carbonyl carbon more electrophilic:

In the case of the Gattermann reaction, we protonate the nitrogen in the nitrile, which will generate an electrophile much as we have seen in the Friedel-Crafts acylation reaction. Here, the Lewis acid coordinates to the nitrogen, generating a formyl-equivalent electrophile that behaves similarly to an acylium ion.
This electrophile is then attacked by the aromatic π electrons in an electrophilic aromatic substitution reaction, forming a sigma complex. Subsequent deprotonation restores aromaticity, and after hydrolysis of the intermediate iminium-type species, the corresponding aromatic aldehyde (Ar–CHO) is obtained:

The Gattermann reaction is similar to the Houben-Hoesch reaction, where an activated aromatic compound reacts with a nitrile under acidic conditions to give an imine intermediate, which is then hydrolyzed to the corresponding aromatic ketone.

Essentially, instead of hydrogen cyanide, an organic nitrile is used, which leads to the formation of a ketone instead of an aldehyde.
A variation of the Gattermann reaction is the Gattermann-Koch reaction, where carbon monoxide and hydrogen chloride are used in the presence of a Lewis acid catalyst to introduce a formyl group onto an aromatic ring, forming aromatic aldehydes:

Another formylation reaction of aromatic compounds is the Vilsmeier-Haack reaction, where the aldehyde group is introduced by using DMF and POCl₃. The idea here is also to generate a highly electrophilic iminium electrophile, which, after electrophilic aromatic substitution, is hydrolyzed to the corresponding aromatic aldehyde.

Check Also
- Electrophilic Aromatic Substitution – The Mechanism
- The Halogenation of Benzene
- The Nitration of Benzene
- The Sulfonation of Benzene
- Activating and Deactivating Groups
- Friedel-Crafts Alkylation with Practice Problems
- Friedel-Crafts Acylation with Practice Problems
- The Wolff-Kishner and Clemmensen Reductions
- Vilsmeier-Haack Reaction
- The Alkylation of Benzene by Acylation-Reduction
- Ortho, Para, Meta in EAS with Practice Problems
- Ortho, Para, and Meta in Disubstituted Benzenes
- Why Are Halogens Ortho-, Para- Directors yet Deactivators?
- Is Phenyl an Ortho/Para or Meta Director?
- Limitations of Electrophilic Aromatic Substitution Reactions
- Orientation in Benzene Rings With More Than One Substituent
- Synthesis of Aromatic Compounds From Benzene
- Arenediazonium Salts in Electrophilic Aromatic Substitution
- Reactions at the Benzylic Position
- Benzylic Bromination
- Nucleophilic Aromatic Substitution
- Nucleophilic Aromatic Substitution Practice Problems
- Reactions of Phenols
- Reactions of Aniline
- Meta Substitution on Activated Aromatic Ring
- Birch Reduction
- Electrophilic Aromatic Substitution Practice Problems
- Aromatic Compounds Quiz
- Reactions Map of Aromatic Compounds