We present a code to generate mock observations of 21 cm intensity mapping experiments. The emphasis of the code is on reducing the computational cost of running a full-blown simulation, trading computational time for accuracy. The code can be used to generate independent realizations of the cosmological signal and foregrounds, which are necessary, for instance, in order to obtain realistic forecasts for future intensity mapping experiments. The code is able to reproduce the correct angular and radial clustering pattern for the cosmological signal, including redshift-space distortions, lightcone evolution and bias. Furthermore, it is possible to simulate a variety of foregrounds, including the potentially problematic polarized synchrotron emission. ; Comment: 17 pages, 12 figures. Replaced to match MNRAS version. Code and data available at http://intensitymapping.physics.ox.ac.uk/CRIME.html