Granted, Clive Griffiths’ side made hard work of it - Bedford had three players sin-binned and Doncaster were clinging on during 10 minutes of injury-time - but there was no doubting their tenacity, Declan Cusack’s boot having finally seen off the visitors.
They round off their regular campaign at London Welsh next weekend before the play-offs begin, Bedford also securing a top-four spot.
Knights saw full-back Paul Jarvis make a successful return from a foot injury suffered in February while Matt Challinor, Latu Makaafi and Mat Clark scored tries allied to Cusack’s two conversions and three penalties.
They got off to a disastrous start, though, when conceding a try inside just 15 seconds.
They failed to deal with the kick-off and Michael Lebourgeois, Bedford’s impressive outside centre, quickly broke through to feed fly-half Myles Dorrian who improved his own try.
The hosts were unruffled, however, and after some sustained pressure, Bedford tighthead Phil Boulton was yellow-carded on 12 minutes for killing the ball, the latest of a litany of infringements. He was lucky to stay on after more foul play later on.
Cusack kicked the penalty but, otherwise, the Knights failed to make the extra man count.
Indeed, they went further behind before Boulton’s return to the field.
Having won a scrum against the head, Doncaster scrum-half Michael Heaney fired out a pass to Tyson Lewis down the short side but the ball went to ground and the visitors countered.
Lebourgeois splintered the home side’s middle once more and, though Mat Clark eventually brought down Josh Buggea, the ball was moved wide for full-back Steffan Jones to cross.
Dorrian converted for a 14-3 lead and, with Cusack unusually failing to get hardly any distance on his penalty kicks to touch and captain Michael Hills making some unfamiliar poor passes, Griffiths’ side looked uneasy.
However, they finally got things right with a superb passage of play, going through the phases numerous times testing Bedford in the visitors’ 22 before Hills smartly tipped on Ben Hunter’s pass for Challinor to scramble over in the corner.
Cusack missed the conversion attempt but Bedford saw their other prop - Tom Williams - yellow-carded for collapsing a scrum in the 39th minute.
Again, though, Doncaster failed to strike, Jon Phelan mistiming his jump at the line-out to allow their opponents another breakaway.
They started the second period strongly with a decent line-out drive from Makaafi but Lewis spilled Paul Jarvis’ pass at the vital moment.
However, Makaafi peeled off the back of their next effort to surge over from 15m and, after lock Mike Flanagan became the next Bedford man yellow carded, Clark scored his try off Heaney’s flat pass on 52 minutes, Cusack making it 22-14.
However, as they did too often, the home side failed to make the restart safe and Dorrian slotted another penalty.
Then, Phelan was sin-binned for failing to retreat 10m at a quick penalty tap and that further encouraged the visitors who scored in the 67th minute via Tom Griffiths, Jake Sharp’s conversion putting them ahead again.
Cusack restart sailed straight out but they were not deterred and, after Clark almost scored following the fly-half’s lovely midfield pass, Cusack slotted another penalty in the 74th minute to regain the lead.
He added his third soon after and, though Bedford pushed late on, they had no answer to Doncaster’s stubbornness and resilience, Joe Sprotson producing a timely ball-steal off Griffiths and then the Blues’ line-out failing 5m from the Knights line deep into injury-time.