An important example of a model category is the category of unbounded chain complexes of R-modules, which has as its homotopy category the derived category of the ring R. This example shows that traditional homological algebra is encompassed by Quillen's homotopical algebra. The goal of this paper is to show that more general forms of homological algebra also fit into Quillen's framework. Specifically, a projective class on a complete and cocomplete abelian category [Ascr ] is exactly the information needed to do homological algebra in [Ascr ]. The main result is that, under weak hypotheses, the category of chain complexes of objects of [Ascr ] has a model category structure that reflects the homological algebra of the projective class in the sense that it encodes the Ext groups and more general derived functors. Examples include the ‘pure derived category’ of a ring R, and derived categories capturing relative situations, including the projective class for Hochschild homology and co-homology. We characterize the model structures that are cofibrantly generated, and show that this fails for many interesting examples. Finally, we explain how the category of simplicial objects in a possibly non-abelian category can be equipped with a model category structure reflecting a given projective class, and give examples that include equivariant homotopy theory and bounded below derived categories.