Messier 31 (M31, NGC 224) is the famous Andromeda galaxy, our nearest large neighbor galaxy, forming the Local Group of galaxies together with its companions (including M32 and M110, two bright dwarf elliptical galaxies), our Milky Way and its companions, M33, and others.
Visible to the naked eye even under moderate conditions, this object was known as the "little cloud" to the Persian astronomer Abd-al-Rahman Al-Sufi, who described and depicted it in 964 AD in his Book of Fixed Stars: It must have been observed by and commonly known to Persian astronomers at Isfahan as early as 905 AD, or earlier. R.H. Allen (1899/1963) reports that it was also appeared on a Dutch starmap of 1500. Charles Messier, who cataloged it on August 3, 1764, was obviously unaware of this early reports, and ascribed its discovery to Simon Marius, who was the first to give a telescopic description in 1612, but (according to R.H. Allen) didn't claim its discovery. Unaware of both Al Sufi's and Marius' discovery, Giovanni Batista Hodierna independently rediscovered this object before 1654. Edmond Halley, however, in his 1716 treat of "Nebulae", accounts the discovery of this "nebula" to the French astronomer Bullialdus (Ismail Bouillaud), who observed it in 1661; but Bullialdus mentions that it had been seen 150 years earlier (in the early 1500s) by some anonymous astronomer (R.H. Allen, 1899/1963).
From Students for the Exploration and Development of Space (SEDS) website