Characteristic classes are invariants of bundles living in the cohomology of the base. The most common examples of characteristic classes are the Chern, Stiefel–Whitney, and Pontryagin classes.

For a topological group $G$, denote the collection of isomorphism classes of principal $G$-bundles on a topological space $X$ by $\operatorname{Prin}_G(X)$. The functor $X \to \operatorname{Prin}_G(X)$ satisfies the criteria of Brown's representability theorem, so there is a space $BG$, called the classifying space of principal $G$-bundles, such that $\operatorname{Prin}_G(X) \cong [X, BG]$.

There is a principal $G$-bundle $EG \to BG$ called the universal principal $G$-bundle; the identification above corresponds to pulling back this bundle. More precisely, for every principal $G$-bundle $E \to X$, there is a map $f_E : X \to BG$ such that $E$ is isomorphic to $f_E^*EG$ and $f_E$ is unique up to homotopy. The map $f_E$ is called the classifying map of $E$.

For any $c \in H^{\ast}(BG; R)$, one can define a characteristic class $c(E) \in H^*(X; R)$ by $c(E) := f_E^*c$. With this definition, it is immediate that the association $E \to c(E)$ is natural: given $g : Y \to X$ continuous, $c(g^*E) = g^*c(E)$.

For real vector bundles, one can take $G = O(k)$, in which case $BO(k) = \operatorname{Gr}_k(\mathbb{R}^{\infty})$. The universal principal $O(k)$-bundle is the tautological bundle and often denoted $\gamma \to \operatorname{Gr}_k(\mathbb{R}^{\infty})$. We have $H^{\ast}(\operatorname{Gr}_k(\mathbb{R}^{\infty}); \mathbb{Z}_2) \cong \mathbb{Z}_2[w_1, \dots, w_k]$ where $\deg w_i = i$. The characteristic classes associated to the $w_i$ are called Stiefel-Whitney classes.

For complex vector bundles, one can take $G = U(k)$, in which case $BU(k) = \operatorname{Gr}_k(\mathbb{C}^{\infty})$. The universal principal $U(k)$-bundle is the complex tautological bundle and often denoted $\gamma^{\mathbb{C}} \to \operatorname{Gr}_k(\mathbb{C}^{\infty})$. We have $H^{\ast}(\operatorname{Gr}_k(\mathbb{C}^{\infty}); \mathbb{Z}) \cong \mathbb{Z}[c_1, \dots, c_k]$ where $\deg c_i = 2i$. The characteristic classes associated to the $c_i$ are called Chern classes.

The above is a more modern way of thinking of characteristic classes. The classical reference is Milnor and Stasheff's *Characteristic Classes*.