The hosts started the game very brightly and could have scored three times in the opening five minutes. Sebastien Corchia had a shot saved before Marco Ilaimaharitra and Sebastien Roudet both fired over the bar.
© Getty Images
Nice finally started to come into the game but it was Sochaux who threatened again in the 20th minute when Carlao's header from a Roudet corner went over.
Just as the first half was looking like ending goalless, Nice defender Nemanja Pejcinovic put the ball into his own net to provide the hosts with a lead that they just about deserved.
They wouldn't have to wait long for their second goal, however, as Ayew again caused problems in the box with some good movement before planting a header beyond Ospina from Corchia's cross.