Schalk Burger and JP Pietersen crashed over in a first half dominated by the powerful Springboks.
The Scots struggled to make inroads until a Duncan Weir interception led to a thrilling Tommy Seymour try.
But the cool kicking of Handre Pollard kept South Africa at a safe distance and Bryan Habana added a late score to reflect the gulf in quality.
Listen to the best of the action on BBC Radio 5 live
The Springboks, twice World Cup winners, signalled that their campaign is back on track with a bludgeoning display of brute force after their shock opening loss to Japan.
Scotland now look ahead to next weekend's clash with Samoa, knowing victory will see them through to the quarter-finals.
The first score came after 13 minutes when a combination of Burger, Bismarck du Plessis and Duane Vermeulen smashed their way through the Scottish defence, with Burger credited with the final touch in a muddle of hands.
Scotland were warned and here was the Springbok maul in all its ferocity. At times the Scots were mauled off the park, never more so than at the end of a one-sided first half when a devastating rumble paved the way for JP Pietersen to touch down.
It was textbook. It came with Jannie du Plessis in the sin-bin. Scotland were in a mightily deep hole.
At the break, such was South Africa's upper hand that you felt Scotland were set for a pummelling, with Heyneke Meyer's team leading by a handsome 17 points.
The revival from Scotland might have been brief but it was heartening.
Weir's epic breakaway and the support from Tim Visser created a try from the blue from Seymour to cut the game to a seven-point margin.
It was a score that rocked the Bokke but just when Scotland needed to consolidate, they blundered.
They made a frightful hash of the restart, then had Greig Laidlaw sent to the bin for a cynical grab at Habana.
Their bravery never let up one for second, though. A sure sign of South Africa's concerned mindset came when Pollard opted for a drop goal to re-establish their cushion.
In the end, the Boks had too much ball and too much power. The physical toll was massive. South Africa did not play cosmic rugby but they played with an intensity that Scotland could not live with.
A do-or-die meeting with the Samoans, who suffered a major loss to Japan. Samoa are out of the World Cup. if Scotland beat them, they make the quarter-finals. Next Saturday back at St James' Park will be huge for the Scots.
Vern Cotter has some decisions to make. Blair Cowan was magnificent and made a mockery of the decision to leave him out of the original 31. If John Hardie is fit, who plays seven next week?
Cotter will be encouraged by some of what he saw. The courage was there in spades against South Africa.
Richie Gray was wonderful. His younger brother, Jonny, was not far behind. Josh Strauss showed up well.
This was a beaten Scotland but a Scotland that is improving and will be considered hot favourites in the must-win game on Saturday - their biggest test in four years.
Scotland captain Greig Laidlaw: "We were disappointed with our performance. It was a poor first half, probably wasn't a great second half either, we just didn't really get out the blocks and paid the price for it.
"We knew [the South African physicality] was coming, we just didn't stop it. We were letting them get that momentum we spoke about. Once they did that it was a nightmare to try and attack.
"The breakdown was a melee; we let them get on the front foot when they were attacking so it was hard to defend.
"That was all nonsense [about Scotland fielding a weakened side] before the game; we're just disappointed with our performance."
South Africa: le Roux, Pietersen, Kriel, de Allende, Habana, Pollard, du Preez, Mtawarira, B. du Plessis, J. du Plessis, Etzebeth, de Jager, Louw, Burger, Vermeulen.
Replacements: Lambie for Pietersen (70), Serfontein for de Allende (75), Pienaar for du Preez (80), Nyakane for Mtawarira (67), Strauss for B. du Plessis (57), Malherbe for J. du Plessis (50), du Toit for de Jager (76), Alberts for Burger (70).
Sin Bin: J. du Plessis (34).
Scotland: Hogg, Seymour, Vernon, Scott, Visser, Weir, Laidlaw, Reid, Brown, Nel, R. Gray, J. Gray, Strauss, Cowan, Denton.
Replacements: Lamont for Hogg (63), Horne for Vernon (65), Hidalgo-Clyne for Laidlaw (70), Dickinson for Reid (51), Ford for Brown (61), Welsh for Nel (64), Swinson for J. Gray (69), Wilson for Strauss (55).
Sin Bin: Laidlaw (53).
Att: 50,900
Referee: Nigel Owens (Wales).
For the latest rugby union news, follow @bbcrugbyunion on Twitter.
South Africa comfortably held off Scotland in Newcastle to take over at the top of World Cup Pool B.