More on KentOnline
A stoppage-time goal looked to have killed off any chances of Gillingham making the League 1 play-offs, however a later one elsewhere kept them alive.
The Gills needed at least a point to keep their hopes alive but were hit by a late winner, though their chances were rekindled by an equaliser for Colchester eight minutes into stoppage-time at Barnsley
It all means Gills need to beat Millwall on the final day and hope Barnsley don't win at champions Wigan and Scunthorpe do no better than a draw at Sheffield United.
Lucas Akins put second[-placed Burton ahead just before the end of the first half but Cody McDonald levelled shortly after the restart.
Gillingham were hanging on before Tom Naylor rose at the far post to head home a corner and win it for Burton.
Gillingham, without a win in six heading to the Pirelli Stadium, needed at least a point to realistically keep their promotion hopes alive.
Failing that, a Barnsley defeat would give them hope, just. Both teams were a goal behind at the break but both found equalisers.
Barnsley ended up winning 2-1. Victory for Scunthorpe dropped the Gills to eighth but their hopes ended with the late goal, leaving them too far adrift of the top six.
Dominic Samuel returned up front for the Gills, going straight into the starting XI at the expense of Luke Norris. His injury absence coincided with Gillingham’s poor run of form.
It was the only change from the team that started the previous week’s match against Shrewsbury, which the Gills lost 3-2.
It was a tough start for the Gills, on the back foot early on as Burton dictated. Two injuries within moments of each other did little to boost their hopes.
Brennan Dickenson was already preparing to replace injured Bradley Garmston when Aaron Morris went down on the edge of the box. He was eventually replaced by returning skipper Doug Loft.
For all of their pressure, Burton’s finishing early on was poor. Stuart Nelson had a routine stop to deny Damien McCrory and there were shots from Akins and Naylor, twice, that went wide of the mark.
The substitutions didn’t hinder the Gills and the break-up in play seemed to benefit them, taking the momentum away from Burton.
McDonald was busy up front, almost getting in on a couple of occasions. Samuel snatched at a half-chance and went wide while Bradley Dack also fired into the side-netting during a good spell for the away side.
But their promotion hopes suffered a setback when Mark Duffy, who had only recently been switched to the right flank, whipped in a cross behind the defence and Akins was there to prod it home with a minute of the half remaining.
It was all-square when McDonald headed home a Dack corner on 49 minutes, for his fifth goal of the season.
The Gills withstood plenty of pressure immediately after the goal but had chances of their own, with Dack and McDonald both shooting wide. Samuel also volleyed over from a Deji Oshilaja cross and McDonald headed another chance the wrong side of the post.
Burton had plenty of the ball but struggled to create clear-cut chances. At the other end Josh Wright sent a shot wide after the defence backed off.
The game was sealed when Naylor headed in at the death, but their season will be decided on the final day.
Burton (4-1-4-1): McLaughlin, Edwards, Cansdell-Sherriff, Mousinho, McCrory, Naylor, Duffy (O’Connor 90mins), Palmer (Walker 85mins), Choudhury, Akins, Beavon (Butcher 75mins). Subs not used: Bywater, Reilly, Weir, Harness.
Gillingham (4-4-2): Nelson, Garmston (Dickenson 14mins), Egan, Ehmer, Oshilaja, Hessenthaler, A Morris (Loft 16mins), Wright, Dack, McDonald, Samuel (Donnelly 74mins). Subs not used: G Morris, Jackson, Williams, Norris, Dickenson.
Attendance: 5,388.