We investigate the relic density n χ of non-relativistic long-lived or stable particles χ in non-standard cosmological scenarios. We calculate the relic abundance starting from arbitrary initial temperatures of the radiationdominated epoch, and derive the lower bound on the initial temperature T 0 ≥ m χ /23, assuming that thermally produced χ particles account for the dark matter energy density in the universe; this bound holds for all χ annihilation cross sections. We also investigate cosmological scenarios with modified expansion rate. Even in this case an approximate formula similar to the standard one is capable of predicting the final relic abundance correctly. Choosing the χ annihilation cross section such that the observed cold dark matter abundance is reproduced in standard cosmology, we constrain possible modifications of the expansion rate at T ∼ m χ /20, well before Big Bang Nucleosynthesis.