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.
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.
England resumed Saturday on 36 without loss after bowling out Sri Lanka on Friday, with Yorkshire fast bowler Liam Plunkett taking Test-best figures of five for 64 and Stuart Broad a hat-trick.
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 compiling 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 in what was an important innings for the 24-year-old, the son of an English mother, after his England debut in the drawn first Test of this two-match series at Lord's yielded scores of just one and 19.
Meanwhile Gary Ballance, fresh from his maiden Test hundred, uppercut seamer Nuwan Pradeep and swept left-arm spinner Rangana Herath for well-struck fours.
Robson's edged boundary off Pradeep saw him to fifty as England were 106 for one at lunch, with Robson 55 not out and Ballance 30 not out.
Ballance had added just one to his lunch score when Herath appealed for lbw.
New Zealand umpire Billy Bowden upheld Sri Lanka's 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 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 as his parents watched from the old Headingley Pavilion.
An increasingly confident Robson subsequently lofted Herath over long-on for six.
It was only his sixth six in 73 first-class matches.
But Robson's six-and-a-quarter hour innings came to an end 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 (74) and 87 for the third with Ian Bell.
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 catch. – AFP