There are such spaces, for example X = S^2 \times RP^3, Y = S^3 \times RP^2. (These are both smooth and CW-complexes.)
Whitehead's Theorem says that for CW-complexes, if a map f : X \to Y induces an isomorphism on all homotopy groups then it is a homotopy equivalence. But, as the example above shows you need the map.
(Whitehead's Theorem is not true for spaces wilder than CW-complexes. The Warsaw circle has all of its homotopy groups trivial but the unique map to a point is not a homotopy equivalence.)