Let $G$ be a Lie group with a left action on a manifold $M$, $\cdot : G \times M \to M$.
Define a $G$-invariant differential form $\alpha \in \Omega^{k}(M)$ as a form satisfying $g^{*}\alpha = \alpha,$ where $g:M \to M$ is the action by $g \in G$. Since pullbacks commute with differentials, the set of all $G$-invariant forms (which I will denote by $\Omega(M)^G$) is a subcomplex of $\Omega(M)$. I found the following theorem in several places:
Theorem: If $G$ is compact and connected, then the inclusion $i: \Omega(M)^{G} \to \Omega(M)$ is induces an isomorphism in de Rham cohomology.
One of the places where I found this is https://planetmath.org/invariantdifferentialform. However, there is no proof there, and I would like to find a proof. Does anyone know a good reference on this subject matter?
Spivak "A comprehensive introduction to Differential Geometry" vol. 5, Look at chapter 13, section 16 pg 308,309.