The tourists, who resumed at 50-2 after a rain-curtailed opening day, moved to 292-8 by stumps on the second day at the Sinhalese Sports Club with Pujara holding fort on a watchful 135 not out.
Pujara, who had been dropped for India’s last four Tests across Australia, Bangladesh and the ongoing series, may not have played this match too if both regular openers Murali Vijay and Shikhar Dhawan had been fit.
The 27-year-old grabbed the chance to notch up his seventh Test century that has so far included 13 boundaries.
Fast bowler Prasad bowled superbly to take four wickets in the innings, including two off successive balls on either side of the lunch break that reduced India to 119-5.
Number nine batsman Amit Mishra came to India’s rescue with a defiant 59 during an eighth wicket stand of 104 with Pujara which boosted the total.
Just 15 overs had been bowled in the 75 minutes of play possible due to rain on the opening day after India had been sent in to bat on a greenish pitch under overcast conditions.
When play resumed under bright skies on the second day, the tourists were restricted to 22 runs in the first 15 overs by some accurate bowling by the Sri Lankans.
Indian skipper Virat Kohli survived a torrid opening over from Prasad in which he was lucky to escape a loud shout for leg-before off the second ball and was beaten by the final ball of the over.
Kohli added four runs to his overnight score of 14 when Sri Lankan captain Angelo Mathews, who replaced Prasad at the bowling crease, had his counterpart caught behind by Kusal Perera.
Rohit Sharma added 55 runs for the fourth wicket with Pujara, scoring 26 with three fours and a six before he edged a catch to first slip off Prasad in what became the final delivery of the morning session.
Prasad, who still had one ball to bowl in the over on resumption, trapped Stuart Binny leg-before with the first delivery to open up India’s lower order.
Debutant wicket-keeper Naman Ojha helped Pujara add 54 for the sixth wicket, himself making 21 before he holed out in the deep attempting to smash off-spinner Tharindu Kaushal out of the ground.
Prasad removed Ravichandran Ashwin with the first ball of a new spell, caught behind by Perera for five, but Mishra joined Pujara to frustrate Sri Lanka.
Mishra reached his half-century by driving seamer Nuwan Pradeep to the cover fence for his seventh boundary, but fell soon after when he was stumped off left-arm spinner Rangana Herath.
The series is locked at 1-1 after Sri Lanka won the opening Test in Galle by 63 runs and India drew level with a 278-run win in the second match at the P. Sara Oval in Colombo on Monday.