The 30-year-old has played every Test for Bangladesh since missing two games against the West Indies in 2014, but earlier Monday requested a six-month sabbatical from the game "to refresh his body".
Bangladesh will also play three one-day internationals and two Twenty20 games in South Africa during their first tour to the country since 2008. Shakib earlier said he would be available for other formats.
"We still cannot think of a team without Shakib. But he wanted a break and it was granted," said chief selector Minhajul Abedin while announcing the team at a press conference in Dhaka.
"He was playing for a long time in all formats. So he needed a rest. Of course, without him we will be on the back foot, still we have to manage it."
More From This Section
He added that Shakib would be welcome back into the team whenever he wished.
In Shakib's absence, Bangladesh selectors recalled batsman Mahmudullah, who missed the recent home series against Australia due to poor form.
"We included Mahmudullah because he can do well abroad, where the ball comes first on to the bat. He is a senior batsman and an experienced batsman," Abedin said.
Pace bowler Rubel Hossain and Subashis Roy also returned to the side while the selectors dropped batsman Nasir Hossain.
The first Test will be held at Senwes Park, Potchefstroom from September 28 to October 2 while Mangaung Oval, Bloemfontein will host the second Test from October 6-10.