Recover a space from its fundamental group? isomorphic fundamental groups

There are a lot of articles on this page, if isomorphic fundamental groups imply some conection between the corresponding spaces, such as homotopy-equivalence. I know a lot of counter examples to this statement, e.g. lens spaces which are compact manifolds and have the same homotopy groups and dimensions, but they are not homotopy-equivalent.

If a map $f :X\to Y$ between connected CW complexes induces isomorphisms $f_\ast :\pi_n(X)→\pi_n(Y)$ for all $n$, then $f$ is a homotopy equivalence. In case $f$ is the inclusion of a subcomplex $X\hookrightarrow Y$ , the conclusion is stronger: $X$ is a deformation retract of $Y$. (cf. Hatcher, p. 346)

Now I have at least two questions:

1.) Can we recover a space from its fundamental group under certain conditions?

I am not interested in trivial answers, but I would like to know, how "good" (i.e. how general) these conditions can be.

2.) Is there another statement, like the one of Whitehead, which gives us the opportunity to find a connection between spaces, if their fundamental groups are isomorphic?

• For (1), being $K(G, 1)$ is probably the best you can get - this means having a contractible universal cover. For (2), if $X$ and $Y$ are moreover simply connected, then knowing that a map $f : X \to Y$ induces isomorphism on homology groups is enough - this is the homology Whitehead theorem. Most often $\pi_1$ is just too weak to recover the space from just knowing that - if $X$ is a CW-complex, $\pi_1(X) \cong \pi_1(X^2)$ where $X^2$ is the $2$-skeleton, so from that you can infer it always captures information about the 2-skeleton. – Balarka Sen Aug 5 '16 at 13:22
• Note furthermore that Whitehead's theorem does not recover the space from just it's homotopy groups: indeed, if $X$ is a CW-complex, then that has the same homotopy groups as $K(\pi_1, 1) \times K(\pi_2, 2) \times K(\pi_3, 3) \times \cdots$. It requires having a potential candidate for a homotopy equivalence, a map. – Balarka Sen Aug 5 '16 at 13:26

To answer you question, the homotopy type of a $K(\pi,1)$ space is determined by its fundamental group.