The McTutor biography on Poincaré says:
Poincaré's Analysis situs, published in 1895, is an early systematic treatment of topology. He can be said to have been the originator of algebraic topology and, in 1901, he claimed that his researches in many different areas such as differential equations and multiple integrals had all led him to topology. For 40 years after Poincaré published the first of his six papers on algebraic topology in 1894, essentially all of the ideas and techniques in the subject were based on his work.
The fundamental group is credited to Poincaré, plus much of homology theory.
What specific problems stimulated his topological work? Was it an outgrowth of his work on celestial mechanics, or automorphic functions, or something else? The McTutor article mentions that he introduced the fundamental group to help classify two-dimensional surfaces, but why was he trying to do that?