Having suffered a shock defeat by Sheriff last time out in Group D, Carlo Ancelotti's men endured no such difficulties at the Olympic Stadium in Kiev.
Sergey Krivtsov's own goal got the ball rolling for the visitor seven minutes before half-time, while Vinicius' quickfire double put them in control after the break.
Further strikes from Rodrygo and Karim Benzema completed the rout as coach Ancelotti claimed his fifth straight victory over Donetsk in this competition.
Despite a bright start at the scene of their 2018 Champions League final triumph over Liverpool, Madrid had a scare in the 23rd minute.
Indeed, Ferland Mendy was forced to clear Ismaily's dangerous cross with Mateus Tete lurking for a tap-in.
But it was the 13-time European champions who hit the front in extremely fortuitous circumstances after 37 minutes, as Lucas Vazquez's hopeful ball towards Benzema was sliced beyond his own goalkeeper by skipper Krivtsov.
Benzema was involved again as Madrid doubled their lead within six minutes of the start of the second half. After Donetsk were caught in possession from a throw-in, the skipper found Luka Modric, whose perfectly weighted first-time ball was delicately finished by Vinicius.
The Brazilian grabbed his second in emphatic fashion just five minutes later.
Receiving the ball from Benzema on the left flank, he embarked on a jinking run into the heart of the host's defence before sweeping the ball past Anatolii Trubin.
Vinicius then turned provider in the 65th minute, demonstrating tremendous vision to cut the ball back for Rodrygo to thump into the roof of the net. Benzema completed the scoring with a neat finish in the dying moments of the contest.