Dilshan, who will be 37 on Monday, is due to a make a formal announcement at a press conference on Thursday, Sri Lanka Cricket spokesman Rajith Fernando told AFP.
"He is retiring from Test cricket but will be available to play in one-day matches," Fernando said.
The aggressive right-hander began his Test career in November 1999 playing against Zimbabwe at Bulawayo and the last of his 87 appearances came against Bangladesh at Colombo in March.
He scored 5,492 Test runs, including 16 centuries, with a batting average of 40.98. He is the sixth highest Test run scorer in Sri Lanka's history.
He also took 39 wickets with his off-spin at an average of 43.87.Dilshan has been a key factor in Sri Lanka's rise to the top of the rankings in Twenty20 cricket, smashing an unbeaten 74 off 51 balls in his last match -- a six-wicket win over South Africa at Hambantota in August.