CleverSphere

N-alkylation of pyridine: practice and mechanism

Reagent: CH₃ITopic: HeterocyclesBasics

Pyridine attacks CH₃I with its nitrogen (SN2): an N-methylpyridinium salt forms. No Friedel–Crafts-type C-methylation takes place.

Example

CH₃I

Pyridine is a base and a nucleophile at nitrogen (the lone pair is not part of the π system). It attacks CH₃I via SN2, giving an N-methylpyridinium salt. The ring is not methylated.

Mechanism step by step

  1. 1

    The lone pair on N (in the ring plane, not part of the aromatic system) attacks the carbon of CH₃I.

  2. 2

    In one SN2 step the N–C bond forms and iodide leaves.

  3. 3

    N-methylpyridinium iodide forms; the ring stays aromatic but is now positively charged.

Practice tasks

Which product forms, which reagent is needed? After each answer you see the explanation.

Task 1 of 3Heterocycles
CH₃I
?

Which main product forms?

Typical mistakes

  • The ring is not attacked at carbon. The lone pair on nitrogen is the nucleophile, so the nitrogen reacts.
  • The ring is not attacked at carbon. The lone pair on nitrogen is the nucleophile, so the nitrogen reacts.

Often confused with: Pyridine N-oxide · Friedel–Crafts alkylation

Frequently asked questions

Why is the N of pyridine nucleophilic but that of pyrrole not?

In pyrrole the N lone pair is part of the aromatic sextet; using it would destroy aromaticity. In pyridine it lies in the ring plane and is available.

Where do pyridinium ions occur?

In the coenzyme NAD⁺: the nicotinamide ring is an N-alkylated pyridinium ion that accepts hydride (NADH).

More reactions: Heterocycles