Chesney Hughes and Rory Burns both threw away centuries that were there for the taking at the Kia Oval, where Surrey finished the second day 86 runs behind Derbyshire with five first innings wickets in hand.
Hughes, the 24-year-old Anguillan left-hander, could hardly drag himself up the pavilion steps after falling four runs short of his second championship hundred of the season.
He had batted with rare discipline for 14 overs to add a painstaking 11 to his overnight 85 when he tried to hit the second delivery with the new ball from Tom Curran over the top and holed out at extra cover. He had batted almost four hours, faced 190 balls and struck eight fours.
Derbyshire, who had resumed on 209/five, had already lost Tom Milnes, on loan from Warwickshire, at 228 when he dragged the ball into his stumps driving at James Burke but Matt Critchley and Tony Palladino, putting bat to ball with some purpose, added 50 in 10 overs to lift Derbyshire to a total of 313.
Both scored 31 before falling to the persevering Tom Curran who finished with five for 71.Zafar Ansari took four for 61 and Surrey had three of the 15 points they needed to be sure of promotion.
Derbyshire were not making it easy for them, however, and their reply stuttered when Tony Palladino had Arun Harinath caught at second slip off his first ball and Kumar Sangakkara caught behind in his third over.
A third wicket partnership of 83 in 24 overs between Burns and Ben Foakes put them back on course but then both of them fell to the part-time off spin of Wes Durston.
Foakes clipped him to short midwicket where Billy Godleman took a good low catch and Burns, who is averaging 53 in the championship this season and had played superbly for his 92 off 136 balls , was out to a hideous-looking shot..
He had already struck 15 fours and another seemed on the way when he got a short ball from Durston but somehow he slapped it tamely to mid off.
Steve Davies was then bowled by Critchley, the 18-year-old leg-spinner, for 22 but Ansari, dropping down the order after his bowling exertions, and Gary Wilson added 55 to take Surrey to 227 for five by the close.
Speaiking at stumps, Wes Durston said: “Their score is very similar to what ours was overnight and we were very happy to to get another 100 or so. The way we’ve stuck at the bowling is very satisfying so it’s very even going into day three.”