We classify all tilting classes over an arbitrary commutative ring via certain sequences of Thomason subsets of the spectrum, generalizing the classification for noetherian commutative rings by Angeleri, Pospíšil, Šťovíček and Trlifaj (2014). We show that the n-tilting classes can equivalently be expressed as classes of all modules vanishing in the first n degrees of one of the following homology theories arising from a finitely generated ideal: TorASTERISK OPERATOR(R/I, -), Koszul homology, Čech homology, or local homology (even though in general none of those theories coincide).
Cofinite-type n-cotilting classes are described by vanishing of the corresponding cohomology theories. For any cotilting class of cofinite type, we also construct a corresponding cotilting module, generalizing the construction of Šťovíček, Trlifaj and Herbera (2014).
Finally, we characterize cotilting classes of cofinite type amongst the general ones, and construct new examples of n-cotilting classes not of cofinite type, which are in a sense hard to tell apart from those of cofinite type.