Having lost their opening three Premier League games without so much as scoring, a tie against the side 92nd in the standings looked just what the doctor ordered for Sean Dyche’s men.
But Everton’s start to the season threatened to go from bad to worse as League Two’s bottom side took a deserved lead through Joe Ironside’s header.
Doncaster were dreaming of a famous win, but the Premier League visitors belatedly showed signs of life as striker Beto – on as a substitute early in the second half – scored a day after signing from Udinese, before Danjuma secured a late 2-1 victory.
It was a gut punch for Grant McCann’s side but a morale-boosting win for the Toffees, although Dyche will be alarmed by much of his side’s display in South Yorkshire, where they return to take on Sheffield United on Saturday lunchtime.
They looked jittery from the outset and Joseph Olowu wasted a great chance from a corner that followed panicked play at the back.
Doncaster continued to unsettle careless Everton, with Tommy Rowe lashing over from a corner before Zain Westbrooke thrashed a 25-yard drive just wide.
“Premier League, you’re having a laugh” rang around the ground as Everton toiled, taking 41 minutes to manage a shot of any kind at the Eco-Power Stadium.
Danjuma slammed that effort across the face of goal and three minutes later the visitors fell behind.
A short corner routine ended with the ball being played to the edge of the box, where Rowe swung over a cross for Ironside to flick a header past Jordan Pickford from six yards.
Offside appeals were legitimate but there is no VAR at this point of the Carabao Cup.
There would have been an immediate Everton response had goalkeeper Ian Lawlor not smartly stopped Amadou Onana, before Pickford prevented Rowe scoring a second in stoppage time.
But Doncaster remained a threat after the break, with George Broadbent seeing a shot saved before Vitaliy Mykolenko blocked a Mo Faal effort with his hand from a Rowe cutback.
Olowu nearly turned a Mykolenko cross past his own goalkeeper and off balance Beto’s left-footed shot off target summed up their night.
But that chance also lit a fire under the new boy and moments later he had his first goal in blue.
Abdoulaye Doucoure played a hopeful ball down the left channel and Beto beat Olowu to smartly direct it home in the 73rd minute.
“We scored a goal” sung the dancing Everton fans, whose team were now in the ascendancy as Beto saw a header hit a post before Danjuma’s curling effort kissed the crossbar.
Play was scrappy as Doncaster attempted to hold on, with James Garner seeing a close-range attempt blocked before Danjuma broke Doncaster hearts.
Cutting in from the left and collecting a return pass, he made just enough space to get away a right-footed snapshot from just inside the box and beat Lawlor.
Doncaster pushed for a leveller but they had run out of gas, while the offside flag denied Beto his second in stoppage time.