The Hammers are understood to have agreed a fee in the region of £25m to sign the 26-year-old, who made 40 appearances in all competitions for the Ligue 1 outfit in 2021-22.
According to Sky Sports News reporter Dharmesh Sheth, Aguerd had the first part of his medical in France on Wednesday, before arriving in London on Thursday ahead of completing the second part within the next 24 hours.
Sheth adds that West Ham have faced competition from Newcastle United for the Morocco international, but the Hammers now seem to have won the race for his signature.
David Moyes has identified Aguerd as one of his primary centre-back targets as he looks to provide more competition for Craig Dawson, Kurt Zouma, Angelo Ogbonna and Issa Diop.
The future of the latter, however, is believed to be uncertain as he has just a year remaining on his contract, and the potential arrival of Aguerd is likely to push the 25-year-old further down the pecking order.
West Ham are also looking to bolster their squad in other areas this summer, and have been linked with the likes of Southampton midfielder James Ward-Prowse and Sevilla forward Youssef En-Nesyri.