Mahela Jayawardene (240) and Thilan Samaraweera (231) set a fourth-wicket Test record stand of 437 runs as Sri Lanka piled up 644 for seven declared on the second day of the first Test against Pakistan in Karachi on Sunday.
Pakistan were 44 for one in reply, opener Salman Butt (23) edging Muttiah Muralitharan to Jayawardene at first slip after Sri Lanka had declared in the final session.
The home side began to fight back on the stroke of tea, dismissing both the double centurions and Tillakaratne Dilshan in the space of 10 balls.
Off-spinner Shoaib Malik and Danish Kaneria shared the three wickets after Jayawardene and Samaraweera had broken a 52-year old batting record with their stand.
They surpassed the fourth wicket partnership of 411 between Peter May and Colin Cowdrey of England set in 1957 against West Indies at Edgbaston.
The partnership of the two batsmen spanned 643 balls and came in 450 minutes.
Jayawardene was the first to fall when he had a lapse of concentration.
Trying to sweep Malik at the total of 614, he was caught brilliantly by keeper Kamran Akmal down the leg side.
His partner Samaraweera, who made his first double century and highest Test score, fell seven balls later at the same score when he was bowled by a flipper from leg-spinner Kaneria.
Pakistan got their third wicket at the same total of 614 when Dilshan was caught behind playing defensively at a doosra from Malik.
Sri Lanka's total is their highest against Pakistan and also the highest by any team at the National Stadium.
The 437-run stand is also the highest for any wicket at the ground by any team.
Pakistan coach Intikhab Alam said the pitch had not been prepared to his team's liking.
"We were not expecting this sort of track. We wanted a surface with some grass and bounce," Alam told a news conference.
"I do not want to make excuses for our performance but let me made it clear we did not ask for this sort of pitch."