We describe a technique for manipulating quantum information stored in collective states of mesoscopic ensembles. Quantum processing is accomplished by optical excitation into states with strong dipole-dipole interactions. The resulting ``dipole blockade can be used to inhibit transitions into all but singly excited collective states. This can be employed for a controlled generation of collective atomic spin states as well as non-classical photonic states and for scalable quantum logic gates. An example involving a cold Rydberg gas is analyzed.