Australia-born opener Sam Robson scored his maiden Test century before Sri Lanka checked England's progress on the second day of the second Test at Headingley on Saturday.
England were 320 for six in reply to Sri Lanka's 257, a lead of 63 runs, at stumps after Robson had made 127 in only his second Test.
But with England on the verge of taking command, Sri Lanka fought back with three wickets late in the day.
And both Matt Prior (three not out) and Chris Jordan (four not out) were dropped before the close.
"It was a special day, I got a bit of a start last night but I just wanted to fight hard this morning and get us into a decent position," 24 year-old Robson told Sky Sports.
Robson's debut, in the drawn first Test of this two-match series at Lord's, his Middlesex home ground, had yielded scores of just one and 19.
"My debut at Lord's was unbelievable, a bit overwhelming in some respects, so I was looking forward to coming up here and focusing on the cricket rather than the party, as it were," Robson explained after scoring a century witnessed by a Headingley crowd that included both his Australian father and English-born mother.
England resumed Saturday on 36 without loss after Yorkshire fast bowler Liam Plunkett had taken Test-best figures of five for 64 on his home ground and Stuart Broad a hat-trick on Friday.
Alastair Cook, the England captain, had added just three runs to his overnight 14 when he nicked paceman Dhammika Prasad to Kumar Sangakkara at first slip.
That left Cook still searching for his first Test century since the last of his England record 25 hundreds at Headingley last year.
But Robson, 21 not out overnight, confidently off-drove Shaminda Eranga for four.
Meanwhile, Gary Ballance, fresh from his maiden Test hundred, hit well-struck fours off both seamer Nuwan Pradeep and left-arm spinner Rangana Herath.
- Luckless -
Robson's edged boundary off Pradeep saw him to 50 and at lunch England were 106 for one.
Ballance had added just one to his lunch score of 30 when Herath struck him on the pad
New Zealand umpire Billy Bowden upheld Sri Lanka's lbw appeal but England challenged and, with the Decision Review System indicating the ball would have turned past leg stump, Yorkshire's Ballance survived.
The Zimbabwe-born left-hander had another reprieve when on 61, he was dropped at short leg off the inside edge by Kaushal Silva, with Herath again the luckless bowler.
Robson also had a break on 78 when he was hit on the pad by Prasad but Sri Lanka, thinking he had hit the ball, did not appeal.
Sri Lanka captain Angelo Mathews brought himself on with England 183 for one off 65 overs.
And the all-rounder's ninth ball did the trick, Ballance (74) edging to wicketkeeper Dinesh Chandimal, recalled after Prasanna Jayawardene broke a finger at Lord's.
Robson, 98 not out at tea, went to three figures with a two into the covers off Prasad before lofting Herath over long-on for six -- only his sixth six in 73 first-class matches.
But Robson's six-and-a-quarter hour innings finished when, after Sri Lanka had taken the new ball, he was bowled between bat and pad by Pradeep to end a 253-ball knock also featuring 15 fours.
Robson put on 142 for the second wicket with Ballance and 87 for the third with Ian Bell, appearing in his 100th Test.
It seemed there was little to stop the experienced Bell joining the select group of seven players who had made hundreds in their 100th Test until, on 64, he didn't get enough on a glance off Eranga and was caught by Chandimal.
England were still on 311 when Joe Root (13), opening the face, was caught behind off Mathews.
The medium-pacer nearly had another wicket when Prior, then on nought, checked a drive only for Mathews to drop the low return chance.
But Sri Lanka struck again when Moeen Ali, playing away from his body, edged Eranga to give Chandimal his fourth catch of the innings.
Jordan had made just one when he thrashed at Prasad and Dimuth Karunaratne at short extra-cover failed to hold a tough chance.