Cristiano Ronaldo’s penalty and an own goal from Levante ‘keeper Diego Marino put the visitors in command before Deyverson pulled one back for Levante before half-time.
However, Isco’s late strike from Ronaldo’s cut-back secured the points in stoppage time.
Real trail second-placed Atletico by four points, but do open up a four-point lead of their own on Villarreal after they were held 0-0 at Celta Vigo.
Barcelona can extend their lead over Atletico at the top to eight points with victory at Rayo Vallecano on Thursday.
Gary Neville’s Valencia moved into the top half of the table as they benefited from spectacular own goal by Malaga goalkeeper Carlos Kameni to win 2-1 at La Rosaleda.
Madrid boss Zinedine Zidane was without a host of first team regulars as the suspended Dani Carvajal and Sergio Ramos joined the injured Marcelo, Luka Modric, Gareth Bale and Karim Benzema on the sidelines.
Real had former Levante ‘keeper Keylor Navas to thank for not getting off to a terrible start as he produced a brilliant save low to his left to prevent Giuseppe Rossi giving the home side a shock lead.
Ronaldo caused controversy with an outburst claiming Madrid “would be top” of the league if his teammates matched his standards after defeat to Atletico at the weekend.
The three-time World Player of the Year made amends by opening the scoring from the spot on 34 minutes after Lucas Vazquez had been tripped inside the area by Lucas Orban.
Injuries to Benzema and Bale opened the door for 18-year-old Borja Mayoral to get his first league start and he took his opportunity when his shot from the edge of the box hit the post and cannoned into the net off Marino’s back three minutes later.
However, Levante were back in the game instantly as the Real defence were caught flat-footed appealing for an offside flag that never arrived and Deyverson slotted into the bottom corner.
Madrid had much better control of the game after the break and Ronaldo was desperately unlucky not to restore their two-goal lead when he struck the post from James Rodriguez’s fine through ball.
However, Zidane’s men needed to rely on Navas once more to secure the points as he made a flying save to parry Ruben Garcia’s shot from distance.
And Isco answered his recent critics with a calm finish from Ronaldo’s cut-back in stoppage time to round off the scoring.
Defeat leaves Levante still rooted to the foot of the table, six points off safety.
Villarreal’s hopes of temporarily usurping Real Madrid into third were dashed in a game of few chances in Vigo as the visitors registered a sixth consecutive clean sheet in La Liga.
Sevilla closed the gap on Villarreal to nine points in their quest for Champions League football as Fernando Llorente’s early strike handed the Europa League holders their 15th straight home win in all competitions, 1-0 over Eibar.
Valencia moved up to ninth as they recovered from Duje Cop’s early deflected opener to register just Neville’s third league win.
Kameni punched the ball into his own net under pressure from Denis Cheryshev just before half-time and Real Madrid loanee Cheryshev completed the turnaround when he fired into the bottom corner five minutes after the break.
Aritz Aduriz continued his push to be included in Spain’s squad for the Euro 2016 with a hat-trick in Athletic Bilbao’s 4-1 win over Deportivo la Coruna to take his tally for the season to 30.