Stuart Broad had five deliveries at last man Nuwan Pradeep and thought he had won the match with the penultimate one when Sri Lanka’s No 11 was initially given out lbw.
But Paul Reiffel’s decision was rightly overturned after Pradeep requested a review, which proved a meaty inside edge.
After Pradeep then edged the final ball from Broad (3-43) short of second slip to close out the match on 201-9, and deny the best efforts of James Anderson (4-25) too, Cook was struggling to decipher between emotions of pride and frustration.
“It’s probably a mixture of both,” he said, having watched Anderson and then Broad bowl his team to the verge of victory.
Instead, they will go to Headingley on Friday for a potential decider in this short series.
But when Sri Lanka reached 159-2 with only 30 overs remaining in theoretical pursuit of 390 to win, it seemed England had no chance of going 1-0 up.
“Obviously at tea, it looked quite a long way away there,” added Cook.
“But when you get so close and then get a decision which ‘wins’ you a Test match overturned, it’s quite hard to take.
“Then for that last nick not to carry too... but it was a great Test match, and that’s what cricket is all about, to go all the way down to the wire – with both sides leaving everything out there.
“Those last few overs, I just thought we were going to get over the line, so it’s disappointing not to.
“(But) you couldn’t ask for anything more.”
Cook had no argument with the DRS process which reprieved Pradeep.
“I’ve always been a big fan of it,” he said.
“It’s to stop the howler and unfortunately, that one was quite a big inside edge.
“It’s gutting to take at that time but as players you want the right decision.
“I know it’s not great, at this precise moment in time when it’s taken a Test match win away, but it was the right decision.”
Cook’s instinctive reaction, soon vindicated, was that – even after Reiffel raised his finger – the game was not really up.
“I didn’t really move too far from my barstool at first slip. I did think he nicked it,” Cook said. “Everyone was saying it was two pads, so I kind of got excited as I wandered over there. But it was a big noise.”
Yorkshire batsman Joe Root, who was named man of the match for his first-innings double hundred, believes that no one can now accuse Cook’s side of being boring.
“It was exciting, wasn’t it?” Root said. “Twelve months ago we were told we’re playing dour cricket. I don’t think anyone can say that now.
“We spoke long and hard about making big scores, individually and as a team, and that’s a great start for the summer.”
Cook’s opposite number Angelo Mathews also had mixed feelings after Pradeep and his fellow tailenders bailed out Sri Lanka – for whom Kumar Sangakkara (61) and Kaushal Silva (57) had earlier made half-centuries.
Wicketkeeper Prasanna Jayawardene also batted for 20 overs with his captain, despite a broken finger.
After Rangana Herath was ninth out, caught down the leg side off Broad – a controversial dismissal in itself, because the left-hander was hit on his glove while it was off the bat handle – Pradeep turned to Mathews to tell him all would be fine.
“He said to me ‘Don’t worry, I’m going to hold on... if they bowl short at me, I’m just going to leave it’,” Mathews said.
“He did exactly that, a great effort – by Rangana Herath as well, and Prasanna Jayawardene with his broken finger. I thought we batted poorly after tea especially. Their bowlers came in really hard, and asked questions of us, but we couldn’t really handle it.
“(Then) I thought it was a great effort by the last pair, Stuart Broad running in hard, especially with the new ball.
“We didn’t want to give up, and go down losing.”
There were some who queried the timing of Cook’s overnight declaration and whether England might have won had he called time earlier on their second innings.
But he scotched that theory.
“The last four overs (on Sunday) went for 40 or 50 runs,” Cook said.
“So if you’d declared (before then) at 330 or 340 (in front) on that wicket, 100 odd for one at lunch, as Sri Lanka were, it would have looked a very short total.
“The four wickets just after lunch on that fourth day cost us without a shadow of doubt.
“Give Sri Lanka some credit there. They bowled well, and made it difficult for us. It was an unsual Lord’s wicket, to be quite as slow as that, but it produced a brilliant game of cricket.”
Scoreboard: Page 19.