  Within the precise cosmological framework provided by the Lambda-Cold Dark
Matter model and standard Big Bang nucleosynthesis, the chemical evolution of
the pregalactic gas can now be followed with accuracy limited only by the
uncertainties on the reaction rates. Starting during the recombination era, the
formation of the first molecules and molecular ions containing hydrogen,
deuterium, helium, and lithium was severely hindered by the low density of the
expanding universe, the intensity of the cosmic radiation field, and the
absence of solid catalyzers. Molecular hydrogen and deuterated hydrogen, the
most abundant species formed in the gas phase prior to structure formation,
played a fundamental role in the cooling of the gas clouds that gave birth to
the first stellar generation, contributing to determine the scale of
fragmentation. Primordial molecules also interacted with the photons of the
cosmic background via resonant scattering, absorption and emission. In this
review we examine the current status of the chemistry of the early universe and
discuss the most relevant reactions for which uncertainties still exist from
theory or laboratory experiments. The prospects for detecting spectral
distortions or spatial anisotropies due to the first atoms and molecules are
also addressed.
