Karunaratne - who had reached 71 not out to lead Sri Lanka to 133-0 at the close of Day 4 - scored 122 as he maintained his perfect record as Test captain.
Tom Latham's drop let Karunaratne off the hook early in Sunday's play and, though the hosts eventually lost their skipper when he edged Tim Southee behind, the damage was already done.
Angelo Matthews (28 not out) picked up the mantle and with the umpires granting an extension prior to lunch he sealed the win, and 60 ICC Test Championship points, when he nudged Trent Boult for a single, with Sri Lanka successfully chasing down 267, bettering their previous record run-chase in Galle (99).
Sri Lanka complete a record chase at Galle to take a 1-0 lead in the #SLvNZ series and collect 60 points in the ICC World Test Championship #WTC21— Sri Lanka Cricket ðÂÂ±ðÂÂ° (@OfficialSLC) August 18, 2019
NZ 249 & 285 v SL 267 & 268/4 (D Karunaratne 122, L Thirimanne 64, A Mathews 28*) SL won by 6 wickets! pic.twitter.com/ybeRXMDszy
After a superb knock in the last session of day four, Karunaratne picked up where he left off, clipping New Zealand's spin bowlers around the pitch with ease.
Karunaratne hit six fours and one maximum, with that huge hit over midwicket from Ajaz Patel bringing up a 150 partnership with Lahiru Thirimanne (64), who was dismissed three overs later when the Black Caps reviewed an initially unsuccessful lbw appeal.
Kusal Mendis (10) was quick to stamp his authority on proceedings - hitting William Somerville for four on his second delivery before he launched a six over long on.
Mendis' cameo was a short one, though, with Patel drawing a lazy sweep that Sri Lanka's number three wedged straight to Jeet Raval.
But Matthews steadied the ship, keeping the strike ticking over between himself and Karunaratne, and the latter ended his long wait for a ninth Test hundred when he lobbed Patel for four.
With the hosts firmly in control, Sri Lanka's batsmen picked up the pace and, though Southee ended Karunaratne's innings before Kusal Perera (23) sent a Boult delivery to Mitchell Santner, Matthews gave Sri Lanka a 1-0 lead in the two-match series four overs later.
For in-depth, objective and more importantly balanced journalism, Click here to subscribe to Outlook Magazine