Sangakkara followed his 200 not out in the previous Test with an unbeaten 222 and Jayawardene made 165 as Sri Lanka piled up 500-4 in their first innings by stumps on the third day at the Asgiriya stadium.
The hosts, having shot Bangladesh out for 131 on Thursday, lead by 369 runs and look certain to declare at the start of the fourth day to seek another big win for a 3-0 sweep of the series.
Sri Lanka, who won the first two Tests by innings margins, celebrated a rain-free day with a run feast after frustrating interruptions on the previous two days restricted play to only 57.3 overs.
Jayawardene and his deputy Sangakkara added a record 311 for the third wicket, Sri Lanka's best partnership against Bangladesh for any wicket.
The duo, who came together in the first session at 74-2, surpassed the 280 by team-mates Thilan Samaraweera and Tillakaratne Dilshan against Bangladesh in 2005.
Left-handed Sangakkara reached his sixth double century and 14th three-figure knock by smashing Bangladesh captain Mohammad Ashraful to the mid-wicket fence for his 26th boundary shortly before stumps.
Jayawardene, who made 127 in the first Test, survived a confident leg-before appeal on zero to make 165, his 18th Test century that was studded with 15 fours and three sixes.
The third six, a spectacular cut over point against fast bowler Shahadat Hossain, brought up Jayawardene's 150.
Jayawardene and Sangakkara punished the wayward Bangladeshi bowling in a spectacular display of aggressive batting that fetched 155 runs in the two-hour afternoon session.
Both batsmen raced neck-and-neck towards three figures, but Jayawardene got there first with a fine cut off Ashraful for two runs.
Sangakkara, who was on 95 at that stage, reached his own landmark in Ashraful's next over by driving him through the covers for his 14th boundary.
The partnership was broken midway through the final session when Jayawardene holed out to the cover region against left-arm seamer Syed Rasel, who claimed all the three wickets to fall to bowlers.
Rasel, who swung the ball in overcast conditions in the morning session, was rewarded with the wickets of openers Upul Tharanga (12) and Michael Vandort (43) in his opening spell.
Bangladesh's misery piled up when Shahadat was taken off the attack by Ashraful after being warned by South African umpire Rudi Koertzen for grunting loudly at the time of delivering the ball.
Jayawardene had complained about Shahadat's grunting in the first Test, saying it was "unacceptable" at the Test level since the noise disturbed the batsman's concentration.
Rasel was unlucky not to dismiss Jayawardene on zero when Indian umpire Suresh Shastri turned down an appeal for leg-before. Television replays indicated a marginal decision that could have gone either way.