Mbappe scored in the 17th minute to cancel out Juan Foyth's opener for the hosts, before the France striker put Madrid ahead for good six minutes later on Saturday (Sunday AEDT).
Long gone are the scoring troubles Mbappe endured in his first months at Madrid. His brace at Villarreal took Mbappe's La Liga tally to 20 goals, only one fewer than Barcelona's Robert Lewandowski.
Mbappe has 31 goals across all competitions since joining from Paris Saint-Germain last summer.
Barcelona are three points behind Madrid, but have played two games less.
Hansi Flick's side visit third-placed Atletico Madrid, who are four points back, on Sunday. They also have a postponed game versus Osasuna still to be played.
Villarreal made it a pulsating game as they attacked in waves, with Alex Baena and Nicolas Pepe helping create a series of chances.
Thibaut Courtois made three good stops for Madrid to deny Pepe, Ayoze Perez, and Pape Gueye in the first half.
But Villarreal paid at the other end, where Mbappe ruthlessly exploited the holes in the Yellow Submarine's defence.
Carlo Ancelotti left Vinicius Junior and Antonio Rudiger on the bench until the final half-hour - with Luka Modric going on shortly afterwards - as the Madrid coach rotated his line-up three days after their gruelling Champions League victory over Atletico Madrid that went to a penalty shootout.