Ronaldo's bullet header from Dani Carvajal's cross in the 84th minute earned Madrid the three points.
After a slow start to the season, Ronaldo has netted 13 goals in his last seven appearances to take his total to 33 in 34 games in all competitions.
But Eibar secured themselves a deserved equaliser five minutes after the restart, as Ramis headed in a corner from Pedro Leon, who provided an assist against his former club for the sixth time, the most he has provided against any other opponent in LaLiga. "He knows he's going to score, he's unique and special". "This victory makes me feel very good, because they were the better side for a while, they played very well", added the coach.
Ronaldo put Madrid ahead in the 34th minute after Luka Modric intercepted a ball from defender Aritz Arbilla and placed a ideal pass for the Portugal forward to control with his chest and fire in.
The win has now temporarily closed the gap between Real and their fierce rivals Atletico Madrid to four points as Zidane's side look to stay in touching distance of the top two.
Eibar went close once more after great footwork in the middle of midfield by Joan Jordan created space for a quick break and after a neat backheel from Inui, Kike fired in a curling effort from the edge of the area, which Keylor Navas was forced to tip around the post.
Bale had a chance to restore Real's lead in the 63rd minute but his header sailed inches wide of the upright. His whipped cross found the leaping Ronaldo and he made no mistake.
Do you ever have any question about anything you wish to ask and get answer?