The pace-spin duo claimed four wickets each as the depleted South Africans were shot out at the stroke of tea on an even-paced wicket at the Sinhalese sports club here on Thursday.
Sri Lanka replied strongly with 128-2 when bad light ended play early, with Kumar Sangakkara unbeaten on 59 and skipper Mahela Jayawardena on 55.
The pair put on 114 for the unbroken third wicket after seamer Dale Steyn had removed openers Sanath Jayasuriya and Upul Tharanga in his first two overs to make Sri Lanka 14-2.
The Proteas, who went to lunch at 78-2, lost their last eight wickets for 91 runs in a dramatic afternoon session to be all out in just 50.2 overs.
Wily off-spinner Muralitharan finished with 4-41 to take his career tally to 639 wickets, second only to Australian record-holder Shane Warne's 685.
Fernando claimed 4-48 and Farveez Maharoof took 2-32 as the South Africans lost the advantage of winning the toss and batting first on an overcast day.
It was South Africa's lowest-ever total against Sri Lanka, falling below the 179 and 189 they managed in two innings of the second Test at the same venue on their previous visit in 2004.
A.B. De Villiers was the only batsman who took on the Sri Lankan bowlers, smashing 65 off 72 balls with the help of eight boundaries.
De Villiers, who was on 47 when last man Makhaya Ntini walked out to bat, scored the remaining 18 runs for his team before holing out in the deep off Muralitharan.
The tourists missed three top players. Captain Graeme Smith and all-rounder Jacques Kallis stayed home because of injuries, while veteran Shaun Pollock opted out due to the birth of his second child.
Pollock was expected to arrive later on Thursday and will be available for the second Test of the two-match series starting at the Sara stadium here on August 4.
Fernando rattled South Africa at the start by clean bowling openers Herschelle Gibbs and Andrew Hall in a hostile first spell to make it 45-2.
Maharoof struck with the second delivery after lunch when he forced Jacques Rudolph to edge a catch to wicket-keeper Prasanna Jayawardena.
Left-handed Rudolph, a late replacement for Smith, had made a fluent 29 before the break with five boundaries.
Ashwell Prince lasted just 15 deliveries in his first stint at the crease as South African captain, scoring one run when he poked at a Maharoof outswinger and gave the wicket-keeper another easy catch.
Muralitharan, who was proving unplayable even in easy batting conditions, drew Hashim Amla out of his crease and had him stumped for 19 to make South Africa 112-5.
It soon became 128-6 as Mark Boucher top-edged a sweep off Muralitharan and the ball ballooned to Jayasuriya at backward short-leg.
Muralitharan trapped Nicky Boje leg-before for five before Fernando removed Andre Nel and Steyn off successive balls.