Group cohomology versus deRham cohomology with twisted coefficients Let $G$ be a simple simply-connected Lie group, let $M$ be a 3-manifold and $P \to M$ a principal $G$-bundle. Let $A$ be a flat connection in this bundle, and let $\text{Ad} P$ be the associated vector bundle. The connection $A$ gives rise to a twisted deRham complex with cohomology $H^i(M,\text{Ad} P)$. Using the holonomy map to identify (gauge equivalence classes of) flat connections with (conjugacy classes of) representations of $\pi_1(M)$, let $\mathfrak{g}_A$ denote the $\pi_1(M)$-module with action given by the composition of the representation with the adjoint representation of $G$. Let $H^i(\pi_1(M),\mathfrak{g}_A)$ be the corresponding group cohomology groups (cf. e.g. Brown).
Now, I would like to have isomorphisms $H^i(M, \text{Ad} P) \to H^i(\pi_1(M), \mathfrak{g}_A)$ for $i = 0, 1$.
In the case where $M$ is a surface of genus at least 2, rather than a 3-manifold, this is worked out in papers by Goldman, but what can we say in this 3-dimensional setup?
 A: In general, a twisted coefficient system on a manifold $M$ (also called a local system by more algero-geometrically minded people) is given by a representation of $\pi_1(M)$
(the holonomy representation, also called the monodromy representation by more algebrao-geometrically minded people).  Conversely, any representation of $\pi_1(M)$ gives a twisted coefficient system on $M$.
(There is no need for $M$ to be a manifold here; any space for which the usual theory of $\pi_1$ and covering spaces goes through would be fine.)
If $V$ is the representation of $\pi_1(M)$, giving rise to the twisted coefficient system $\mathcal L$, then
there will be map  $H^i(\pi_1(M), V) \to H^i(M,\mathcal L)$.
However, these will not be isomorphisms in general unless $M$ is aspherical,
i.e. if its universal cover $\tilde{M}$ is  contractible, i.e. if $M$ is a $K(\pi,1)$ (for $\pi = \pi_1(M)$).  (Here I am recalling the basic topological interpretation of group cohomology, which you can find in many places.)
What happens in general is that there is a spectral sequence (a special case of the Hochschild--Serre spectral sequence)
$$H^i(\pi_1(M), H^j(\tilde{M},V) ) \implies H^{i+j}(M,\mathcal L).$$
Note that if $M$ is hyperbolic (or, more generally, negatively curved), then
its universal cover is contractible, and so one does get your desired isomorphism.
Added: To get a feeling for what can happen if $\tilde{M}$ is not contractible, you can consider the case when $M = \mathbb RP^2$, so that 
$\tilde{M}$ is $S^2$ and $\pi_1(M)$ is cyclic of order $2$, acting on $S^2$ by the antipodal map.  Take $V$ to be the trivial representation (over $\mathbb Z$, or $\mathbb Z/2\mathbb Z$, say).  Then the preceding spectral sequence gives a way to compute the cohomology (with $\mathbb Z$-coefficients, or $\mathbb Z/2\mathbb Z$-coefficients) in terms of the group cohomology of the cyclic group of
order two acting on the cohomology of the sphere.  (So it acts trivially
on $H^0$, and by $-1$ on $H^2$.)
Of course, you could do the analogous computation for $\mathbb R P^3$ as well
(which is more directly relevant to your question).
