Anatabine is a major alkaloid in Nicotiana tabacum and its isomer, isoanatabine, was recently found in a marine worm. Reduction of 1-methylpyridinium iodide with sodium borohydride gave 1-methyl-3-piperideine, which was transformed with hydrogen peroxide into the N-oxide. Reaction of the N-oxide successively with trifluoroacetic anhydride and potassium cyanide gave 2-cyano-1-methyl-3-piperideine. Its reaction with 3-pyridylmagnesium chloride gave (6)-N-methyl-isoanatabine. This was transformed with m-chloroperbenzoic acid into the N-oxide which was N-demethylated with iron(II) sulfate, giving (6)-isoanatabine. The successive applications of literature procedures for the N-demethylation by decomposition of N-oxide contributed to the knowledge of the mechanism of this oxidative rearrangement. On the other hand, the reduction of 1-methylpyridinium iodide with sodium borohydride and with potassium cyanide present since the start of the reaction in a two layer ether-water system, gave 2-cyano-1-methyl-4-piperideine. This was transformed into (6)-anatabine by the same sequence of reactions used for the synthesis of (6)-isoanatabine.