We review state-of-the-art theory and experiment of the motion of cold and ultracold atoms coupled to the radiation field within a high-finesse optical resonator in the dispersive regime of the atom-field interaction with small internal excitation. The optical dipole force on the atoms together with the back-action of atomic motion onto the light field gives rise to a complex nonlinear coupled dynamics. As the resonator constitutes an open driven and damped system, the dynamics is non-conservative and in general enables cooling and confining the motion of polarizable particles. In addition, the emitted cavity field allows for real-time monitoring of the particle's position with minimal perturbation up to sub-wavelength accuracy. For many-body systems, the resonator field mediates controllable long-range atom-atom interactions, which set the stage for collective phenomena. Besides correlated motion of distant particles, one finds critical behavior and non-equilibrium phase transitions between states of different atomic order in conjunction with superradiant light scattering. Quantum degenerate gases inside optical resonators can be used to emulate opto-mechanics as well as novel quantum phases like supersolids and spin glasses. Non-equilibrium quantum phase transitions, as predicted by e.g. the Dicke Hamiltonian, can be controlled and explored in real-time via monitoring the cavity field. In combination with optical lattices, the cavity field can be utilized for non-destructive probing Hubbard physics and tailoring long-range interactions for ultracold quantum systems.