The main share index gained 1.11 percent, or 62.07 points, to close at 5,667.33.
Foreign investors were net sellers of 286.8 million rupees worth of shares on Tuesday, but have been net buyers of 18.32 billion rupees so far this year.
The bourse is in oversold territory, with the 14-day Relative Strength Index on Tuesday at 29.649, below its lower neutral level of 30, Thomson Reuters data showed.
'Investors might be thinking it is the right time to come back,' a stockbroker said.
Shares in Ceylon Tobacco Co PLC rose 1.91 percent to 1,050 rupees, while top conglomerate John Keells Holdings Plc gained 1.26 percent to 209 rupees.
Tuesday's turnover was 629.7 million rupees ($4.73 million), less than this year's daily average of about 884.7 million rupees.
($1 = 133.0000 Sri Lanka rupees)
(Reporting by Ranga Sirilal and Shihar Aneez; Editing by Prateek Chatterjee)
(Reuters Messaging: firstname.lastname@example.org)(twitter.com/rangab a)