The Frenchman’s tap-in gave Real the lead, but Fernando hit back for Shakhtar just before half-time.
Both sides had chances in the second-half, but Benzema’s 13th goal of the season proved to be the difference.
Real went into the match on 999 Champions League goals in their history, and it was no surprise that the 1,000 milestone came with a Benzema strike.
It was a goal of Shakhtar’s making though, an ambitious attempt at playing out from the back catching them out.
Vinicius Junior robbed Marlon Santos, and squared it to his teammate for a tap-in.
The visitors responded impressively, and they levelled after 39 minutes. Alan Patrick chested down a ball over the top and Fernando hammered home, as the sides went in at the break level.
Shakhtar looked the more likely to take the lead in the second-half, but it was Real who went ahead.
Vinicius combined brilliantly with Casemiro before squaring to Benzema, who finished with aplomb.
Stepanenko went close to earning Shakhtar a point, but Real held on for a win that takes them top of Group D before Sheriff Tiraspol host Inter Milan.