An eventful affair at the Bernabeu saw Real Madrid close the gap at the top of the table.
The hosts put on the early pressure and it paid off with an early goal. A Marcelo cross met a rising Ronaldo only to riochet off the cross bar to Karim Benzema, who head home into an empty net.
The lead didnt last long as Malaga began to threaten soon after conceding. This time, Madrid were to fall from a good cross into the box. Malaga frontman, Rolan, chested down and slammed in the equaliser.
A few minutes later and Madrid would once again go into the lead. This time it was from a corner, an umarked Casimero heading home to restore the lead for Los Blancos once more.
A crazy half was capped off with a crazy decision, the referee ruling out a legitmate Malaga goal. The visitors had earned a free kick and it appeared to have equalised when Carvajal was outmuscled by his marker. The referee bizarrely ruled it out and Madrid were fortunate to go in at the break 2-1 up.
Roberto had been a promient figure in the Malaga goal and was called into action early in the second half to save a Toni Kroos stinger from outside the box. Malaga then went up the other end with a long range effort of their own through Castro, only this one went in despite Castilla appearing to get hands to it.
The away team hadnt previously scored on their travels so far this season, but, Madrid ensured that their awful away form continued. A clear penalty on Luka Modric was converted on the rebound by Cristiano Ronaldo to give Real the lead.
The champions were then denied a goal of their own with Lucas Vazquez incorrectly ruled offside.
Madrid get away with the three points despite riding their luck at times. They close the gap to seven with league leaders facing second place Valencia tomorrow. Malaga meanwhile will feel that they were robbed a point, but, can go home with alot of positives.