Organic Chemistry
The Vilsmeier-Haack Reaction
Bolt an aldehyde onto an electron-rich ring using DMF and POCl₃
The Vilsmeier-Haack reaction formylates electron-rich arenes and heteroarenes by combining DMF with POCl₃ to make a chloroiminium electrophile. Aqueous workup hydrolyzes the iminium salt to an aryl aldehyde — the standard mild route to compounds like p-dimethylaminobenzaldehyde and indole-3-carbaldehyde.
- First reported1927 (Vilsmeier & Haack)
- MechanismElectrophilic aromatic substitution (SEAr) + hydrolysis
- ReagentsDMF + POCl₃ (or oxalyl chloride)
- ElectrophileChloroiminium [Me₂N⁺=CHCl]
- Best substratesAnilines, phenols, pyrroles, indoles
- ProductAryl / heteroaryl aldehyde (Ar-CHO)
Interactive visualization
Press play, or step through manually. The visualization is yours to drive — try it before reading on.
Watch the 60-second explainer
A condensed visual walkthrough — narrated, captioned, under a minute.
What the Vilsmeier-Haack reaction does
The Vilsmeier-Haack reaction is the go-to way to hang a –CHO group (an aldehyde) directly onto an electron-rich aromatic ring. It solves a problem that Friedel-Crafts acylation cannot: there is no bench-stable "formyl chloride" (HCOCl decomposes instantly to CO and HCl), so you can't just acylate benzene with a one-carbon acid chloride. Vilsmeier hides the one-carbon fragment inside a stable, nitrogen-stabilized electrophile — the chloroiminium ion — that only reveals itself as an aldehyde when you add water at the end.
The whole reaction is two acts. First, dimethylformamide (DMF) plus phosphoryl chloride (POCl₃) generate the electrophile — the "Vilsmeier reagent." Second, that electrophile does textbook electrophilic aromatic substitution on an activated ring; the resulting iminium salt is then hydrolyzed on workup to reveal the aldehyde:
Ar-H + DMF + POCl₃ ──→ Ar-CH=N⁺Me₂ Cl⁻ ──H₂O──→ Ar-CHO + HNMe₂·HCl
where Ar-H is electron-rich: aniline, phenol, anisole, pyrrole, furan, thiophene, indole
The key intuition: the nitrogen of DMF is doing the heavy lifting. Its lone pair stabilizes the positive charge on the carbon (that's what makes an iminium ion an accessible, tameable electrophile instead of an unstable acylium), yet it's a good enough leaving group as its protonated dimethylamine that water can pop it off at the end and drop in a C=O.
The mechanism, arrow by arrow
Follow the electrons through four stages. The one-carbon unit starts as the carbonyl carbon of DMF and finishes as the carbonyl carbon of the aldehyde.
- Activate DMF (make the Vilsmeier reagent). The carbonyl oxygen of DMF is nucleophilic; its lone pair attacks the electrophilic phosphorus of POCl₃, displacing one chloride and giving an O-phosphorylated iminium, [Me₂N=CH-O-POCl₂]⁺. A chloride ion then adds to the iminium carbon and the dichlorophosphate (⁻OPOCl₂) leaves, installing a C–Cl bond. The result is the chloroiminium ion, [Me₂N⁺=CHCl], the actual reactive electrophile; with POCl₃ its counterion is the dichlorophosphate anion, so the salt is [Me₂N⁺=CHCl][Cl₂PO₂]⁻. (From DMF + oxalyl chloride the counterion is instead chloride, [Me₂N⁺=CHCl]Cl⁻, and this salt is an isolable crystalline solid.)
- Electrophilic aromatic substitution. The π electrons of the electron-rich ring attack the chloroiminium carbon. Because that carbon is electrophilic but not violently so, only activated rings react. This forms a σ-complex (arenium ion / Wheland intermediate) in which the new C–C bond and the –CHClNMe₂ group sit on an sp³ ring carbon.
- Rearomatize. A base (chloride, or the phosphate byproduct) removes the ring proton from that sp³ carbon, restoring aromaticity and giving a neutral α-chloroamine, Ar–CHCl–NMe₂. This intermediate immediately loses chloride (the nitrogen lone pair pushes it out) to form the resonance-stabilized aryl iminium salt, Ar–CH=N⁺Me₂ Cl⁻. At this point — if you filter and dry — you have isolated the iminium salt, not the aldehyde.
- Hydrolysis (the aldehyde is born here). On aqueous, mildly basic workup, water adds to the iminium carbon to give a hemiaminal, Ar–CH(OH)–NMe₂. Collapse of the hemiaminal expels dimethylamine (protonated to Me₂NH·HCl) and leaves the aldehyde, Ar–CHO. The oxygen of the product comes from the workup water — a detail worth remembering.
step 1: Me₂N-CHO + POCl₃ → [Me₂N⁺=CHCl][Cl₂PO₂]⁻ (Vilsmeier reagent)
step 2: Ar-H + [Me₂N⁺=CHCl] → arenium ion (σ-complex)
step 3: σ-complex → Ar-CHCl-NMe₂ → Ar-CH=N⁺Me₂ Cl⁻ + H⁺ (iminium salt)
step 4: Ar-CH=N⁺Me₂ + H₂O → Ar-CH(OH)-NMe₂ → Ar-CHO + Me₂NH
Reagents, catalyst, and conditions
- The formamide. Almost always DMF (N,N-dimethylformamide). It doubles as the C1 source and often as the solvent. N-methylformanilide (PhN(Me)CHO) is the classic alternative — bulkier, sometimes cleaner on delicate substrates, and it delivers the same –CHO.
- The chlorinating agent (the "acid chloride"). POCl₃ is standard and cheap. Oxalyl chloride (COCl)₂ is milder and gives a cleaner, isolable Vilsmeier salt; thionyl chloride, phosgene, and triphosgene also work. Typically 1.0–1.5 equiv relative to the arene, with the formamide in excess or as solvent.
- No separate Lewis acid needed. Unlike Friedel-Crafts, there is no AlCl₃. The POCl₃ both dehydrates DMF and provides the leaving group; the electrophile is self-contained.
- Temperature. Preform the reagent cold (0–5 °C, DMF + POCl₃ added dropwise — this step is exothermic), then warm the arene mixture. Reactive heterocycles (pyrrole, indole) react at 0–25 °C; sluggish substrates need 60–100 °C for a few hours.
- Workup. Quench onto ice, then adjust to mildly basic (aqueous NaOAc, Na₂CO₃, or NaOH) to drive the iminium hydrolysis to completion. Extract, and the aldehyde falls out.
A practical note: because POCl₃ and the intermediates react violently with water and liberate HCl, this is an anhydrous reaction until the deliberate quench. Keep it dry, add POCl₃ slowly with cooling, and quench carefully into ice — never the reverse.
Scope, selectivity, and regiochemistry
Vilsmeier-Haack is substrate-selective: the mild chloroiminium electrophile only touches strongly activated rings. That's a feature, not a bug — it lets you formylate one ring in a molecule and ignore an unactivated one.
- N,N-dialkylanilines → formylate cleanly para to nitrogen. N,N-dimethylaniline gives p-dimethylaminobenzaldehyde in high yield — the reagent for Ehrlich's and Kovács' spot tests.
- Phenols and anisoles → para-selective (with minor ortho). 2-Naphthol formylates at C-1.
- Pyrrole, furan, thiophene → formylate at the 2-position (α), the most nucleophilic carbon. Pyrrole-2-carbaldehyde and 2-thiophenecarbaldehyde are made this way at scale.
- Indole → formylates at C-3, giving indole-3-carbaldehyde — the workhorse building block toward tryptamines, auxins, and pharmaceuticals.
- Fails on benzene, toluene, halobenzenes, nitroarenes, pyridine, and any electron-poor ring: the electrophile is too gentle to build the arenium ion.
There is no stereochemistry to worry about at the formyl carbon (the product aldehyde carbon is sp²). Regiochemistry follows ordinary SEAr directing effects: the activating group already on the ring steers the electrophile to its ortho/para positions, and sterics push it toward the open para site when it is available.
Vilsmeier-Haack vs other arene formylations
| Vilsmeier-Haack | Gattermann-Koch | Reimer-Tiemann | |
|---|---|---|---|
| Formyl source | DMF (C=O carbon) | CO gas | CHCl₃ + base (dichlorocarbene) |
| Electrophile | Chloroiminium [Me₂N⁺=CHCl] | Formyl cation equiv. [HC≡O]⁺ | :CCl₂ (dichlorocarbene) |
| Catalyst / activator | POCl₃ (no Lewis acid) | AlCl₃ + CuCl, HCl | NaOH / KOH (strong base) |
| Substrate scope | Activated arenes & heterocycles | Simple arenes (benzene, toluene) | Phenols only |
| Regiochemistry | o,p by directing group; C-2/C-3 on heterocycles | para-selective | ortho-selective (chelation) |
| Conditions | Mild, 0–100 °C, anhydrous | High-pressure CO, corrosive | Hot aqueous base |
| Typical yield | High (70–95% on good substrates) | Moderate | Low–moderate (often <50%) |
| Works on pyrrole/indole? | Yes — the standard method | No | No (needs phenolic OH) |
| Where the aldehyde O comes from | Workup water | CO | Water / hydrolysis |
Worked example: p-dimethylaminobenzaldehyde
Make p-dimethylaminobenzaldehyde (the Ehrlich reagent) from N,N-dimethylaniline — a textbook Vilsmeier.
PhNMe₂ + DMF + POCl₃ ──0→90 °C──→ workup (H₂O, NaOAc) ──→ 4-Me₂N-C₆H₄-CHO
- Reagents. N,N-dimethylaniline 1.0 equiv, dry DMF (solvent + C1 source, large excess), POCl₃ 1.1–1.3 equiv.
- Procedure. Cool DMF to 0–5 °C, add POCl₃ dropwise (exothermic) to form the Vilsmeier reagent; stir 30 min. Add the dimethylaniline, then heat to 80–90 °C for 1–3 h. The para position is open and activated, so substitution is fast and clean.
- Workup. Pour onto crushed ice, then basify carefully with aqueous sodium acetate or NaOH to hydrolyze the iminium salt to the aldehyde. Filter or extract.
- Yield. Typically 80–90%, essentially all para; the amine nitrogen directs and the ring is only formylated once (the aldehyde deactivates the ring against a second attack).
Note the amino group survives: unlike Friedel-Crafts, there is no Lewis acid to be poisoned by the basic nitrogen. The dimethylamino group is exactly what makes the ring reactive enough in the first place.
Real-world applications
- Indole-3-carbaldehyde. The single most run Vilsmeier reaction in medicinal chemistry: indole + DMF/POCl₃ → indole-3-carbaldehyde in ~90%. From there, reductive amination, Wittig, or Knoevenagel chemistry builds tryptamine drugs, plant-hormone auxins (indole-3-acetic acid), and countless kinase-inhibitor scaffolds.
- Cyanine and phthalocyanine dyes. Vilsmeier formylation of electron-rich heterocycles installs the aldehyde that then condenses to the polymethine bridge of cyanine dyes and to the meso-formyl group of porphyrins/phthalocyanines used in dyes, sensors, and photodynamic therapy.
- Chromone and coumarin synthesis. Applied to o-hydroxyacetophenones, Vilsmeier conditions formylate and cyclize in one pot to chromone-3-carbaldehydes — versatile intermediates for flavonoid and coumarin natural products.
- p-Dimethylaminobenzaldehyde (PDAB). Made industrially by Vilsmeier; it is the active component of Ehrlich's reagent (urobilinogen/indole test) and Kovács' reagent (detecting bacterial indole production).
- Chlorovinyl aldehydes from ketones. Enolizable ketones and acetophenones undergo Vilsmeier to give β-chloro-α,β-unsaturated aldehydes (β-chlorovinyl aldehydes) — key precursors to pyrimidines, quinolines (via the Meth-Cohn quinoline synthesis), and other heterocycles.
Limitations and side reactions
- Only activated rings react. If your target ring is benzene-like or electron-poor, Vilsmeier simply does nothing — reach for Gattermann-Koch, directed metalation + DMF quench, or a formyl-Grignard equivalent instead.
- Over-chlorination. With excess POCl₃ and forcing temperatures, some substrates get chlorinated on the ring or on side chains. Phenols can give chloro-aldehydes; keep the POCl₃ stoichiometry tight.
- The iminium can be the endpoint. Incomplete or too-acidic workup leaves you with the water-soluble iminium salt rather than the aldehyde. A proper mildly basic hydrolysis (NaOAc, Na₂CO₃) is essential.
- Corrosive, exothermic setup. POCl₃ + DMF is vigorously exothermic and evolves HCl; a runaway addition can boil the flask. Add slowly with cooling and good ventilation.
- Sensitive functional groups. Acid-labile protecting groups, some free amines, and easily oxidized substrates may not survive the acidic, dehydrating conditions.
Historical discovery
The reaction is named for Anton Vilsmeier and Albrecht Haack, who reported it in 1927 (Berichte der deutschen chemischen Gesellschaft) while studying the action of N-methylformanilide and phosphoryl chloride on electron-rich aromatics. Vilsmeier worked in the German dye industry, and the reaction's early value was precisely in making the aromatic aldehydes that feed dye synthesis. The role of the discrete chloroiminium (chloromethyleneiminium) ion as the reactive electrophile was clarified in later decades, and the isolable salt from DMF and oxalyl chloride made the mechanism concrete. Today it is one of the most widely used named reactions in heterocyclic and dye chemistry.
Safety and industrial notes
- POCl₃ is a corrosive, moisture-sensitive liquid that hydrolyzes to phosphoric and hydrochloric acids; it is toxic by inhalation. Handle under inert atmosphere with scrubbing for HCl fumes.
- DMF is a reprotoxic solvent (suspected of harming fertility/the unborn child); use closed systems and avoid skin contact.
- Quench discipline. The reaction stream must be added onto excess ice-water, not the other way around, to control the exotherm and acid evolution.
- Scale. On process scale, oxalyl chloride or triphosgene is often preferred over POCl₃ because the phosphorus waste stream (phosphate salts) is cut, and the exotherm is easier to control. The chemistry runs cleanly in kilo-lab to plant scale for pharmaceutical aldehyde intermediates.
- Atom economy. Vilsmeier is not atom-economical — the nitrogen leaves as dimethylamine and phosphorus as phosphate — but its reliability, mildness, and generality on heterocycles keep it a workhorse where cleaner formylations fail.
Frequently asked questions
What is the Vilsmeier reagent, and how is it made?
The Vilsmeier reagent is a chloroiminium salt, [Me₂N⁺=CHCl]Cl⁻ (also drawn as the chloromethyleneiminium ion). You make it in situ by mixing a disubstituted formamide — almost always N,N-dimethylformamide (DMF) — with an acid chloride such as phosphoryl chloride (POCl₃) or oxalyl chloride. The carbonyl oxygen of DMF attacks phosphorus, and chloride then displaces the phosphate leaving group to install a C–Cl bond, producing the electrophilic chloroiminium carbon that does the formylation.
Why does Vilsmeier-Haack only work on electron-rich arenes?
The chloroiminium ion is a fairly weak electrophile — far softer than an acylium or a nitronium ion. It only reacts fast enough with rings that are strongly activated: anilines (especially N,N-dialkylanilines), phenols and their ethers, and π-excessive heterocycles such as pyrrole, furan, thiophene, and indole. Benzene, toluene, and any electron-poor arene (nitrobenzene, benzaldehyde, pyridine) are unreactive under standard Vilsmeier conditions.
Where does the aldehyde oxygen come from?
Not from DMF's original oxygen and not from POCl₃. After electrophilic substitution you have an aryl-substituted iminium salt, Ar–CH=N⁺Me₂. The C=O of the final aldehyde is installed during the aqueous workup: water adds to the iminium carbon, and hydrolysis expels dimethylamine (as its hydrochloride) to unmask Ar–CHO. Skip the water quench and you isolate the iminium salt instead of the aldehyde.
What is the regiochemistry of Vilsmeier formylation?
It follows normal electrophilic aromatic substitution directing rules. N,N-dimethylaniline formylates almost exclusively para to the amino group (para is open and sterically clear). Phenols and anisole go para (with some ortho). Pyrrole and furan formylate at the 2-position (alpha); indole formylates at C-3, the most nucleophilic carbon of the indole ring. Where the para position is blocked, the electrophile takes the ortho site.
How is Vilsmeier-Haack different from Friedel-Crafts formylation?
You cannot run a plain Friedel-Crafts acylation with formyl chloride (HCOCl) because that acyl chloride does not exist — it decomposes to CO and HCl. Vilsmeier sidesteps that by carrying the one-carbon unit as a stable, storable iminium electrophile that only becomes an aldehyde on workup. Compared with the other formyl workarounds — Gattermann-Koch (CO/HCl/AlCl₃) and Reimer-Tiemann (CHCl₃/base) — Vilsmeier is milder, higher-yielding on activated substrates, and by far the most general for heterocycles.
Is DMF the only formamide you can use?
No, but it is the default. Any N,N-disubstituted formamide works — N-methylformanilide is a classic alternative that is often used to formylate more sensitive substrates and gives cleaner reactions with some phenols. Using a substituted amide instead of formamide (e.g. N,N-dimethylacetamide) delivers a ketone rather than an aldehyde, because the transferred carbon now carries a methyl group. That variant, the Vilsmeier-type acylation, installs Ar–C(=O)CH₃.