Cell-free extracts of Neurospora crassa mycelium catalyze the methylation of l-histidine to form hercynine (histidine betaine). The partially methylated compounds, alpha-N-methyl-l-histidine and alpha-N,N-dimethyl-l-histidine, are also methylated by the same enzyme preparation to form hercynine. All three methylation reactions are stimulated by the addition of S-adenosylmethionine.