Enes Unal scored the only goal after just nine minutes when he robbed Eder Militao of possession inside Real Madrid’s penalty area.
Luka Modric went closest to an equaliser, striking the crossbar with a powerful drive.
Carlo Ancelotti’s side have played two games more than closest challengers Sevilla, who face Cadiz on Monday.
Real dominated the first half but only forced one save from Getafe goalkeeper David Soria, who did magnificently to tip Modric’s long-range drive past the far post.
The Croatian midfielder also struck the woodwork with a thunderous left-footed shot from the edge of the Getafe penalty area, while Toni Kroos fired wide from a promising position.
Real increased the pressure in the second half and went close to salvaging a point through Casemiro, but the midfielder’s sweetly struck effort was palmed to safety by Soria.