A versatile, one-pot synthesis of 2-arylimidazole-4-carboxylic acids from arylamidines and methyl-2-chloroacetoacetate is described. The transformation is chemoselective, and reaction conditions are mild. Moreover, the flexibility of the strategy offers rapid access to two important classes of biaryl compounds, both 2-arylimidazoles and 2-arylpyrimidines, depending simply upon solvent and base selection. [reaction: see text]