Kuldeep Yadav and Vijay Shankar, who were part of the team for the Sri Lanka Tests, did not find a place in the squad.
"When you go to South Africa, you definitely require two wicketkeepers, you can not take a chance".
The T20I series between India and Sri Lanka, meanwhile, is scheduled on December 20, 22 and 24.
India's T20 squad against Sri Lanka: Rohit Sharma (c), Lokesh Rahul, Shreyas Iyer, Manish Pandey, Dinesh Karthik, M S Dhoni, Hardik Pandya, Washington Sundar, Jasprit Bumrah, Yuzvendra Chahal, Kuldeep Yadav, Deepak Hooda, Mohd Siraj, Basil Thampi, Jaydev Unadkat. The decision is most likely taken to provide him with enough rest as the Indian team embarks on a tough mission of the South Africa tour.
The biggest question mark was over Jasprit Bumrah's selection for the South Africa series.
The right-arm pacer comes into the side at the back of some impressive showing in limited-overs cricket for India. Also, he has had decent returns in first-class cricket, with 89 wickets in 26 matches.
"Considering his Ranji Trophy performance past year, it was a unanimous decision".
The frontline pace attack includes the likes of Mohammed Shami, Ishant Sharma, Umesh Yadav, Bhuvneshwar Kumar and Bumrah.
India will play three Tests, six one-dayers and three T20 matches during the tour of South Africa which will kick off with a warm-up game in Paarl on December 30. They also play six one-day and three Twenty20 matches.
Virat Kohli, who was earlier rested for the upcoming three-match ODI series against Sri Lanka, starting Sunday, has also been rested for the three-match T20I series to be followed.
The 17-member Test team squad: Virat Kohli (Capt), Vijay, Rahul, Shikhar, Pujara, Rahane (vc), Rohit, Saha (wk), Ashwin, Jadeja, Parthiv, Hardik, Bhuvneshwar, Shami, Ishant, Umesh, Bumrah.