Sarfraz Ahmed apologised on Twitter.
Sarfraz was heard making a comment in Urdu about Phehlukwayo.
Sarfraz could face disciplinary action from the ICC.
Pakistan captain Sarfraz Ahmed apologised on Wednesday following a controversial comment aimed at South Africa's Andile Phehlukwayo which was picked up by a stump microphone during the second one-day international in Durban on Tuesday. Sarfraz was heard making a comment in Urdu about Phehlukwayo during the South African all-rounder's match-winning partnership with Rassie van der Dussen.
It is widely reported that Sarfraz could face disciplinary action from the International Cricket Council (ICC). The Pakistan captain tweeted: "I wish to extend my sincere apologies to any person who may have taken offence from my expression of frustration which was unfortunately caught by the stump mic during yesterday's game against SA.
"My words were not directed towards anyone in particular and I certainly had no intention of upsetting anyone.
"I did not even mean for my words to be heard, understood or communicated to the opposing team or the cricket fans. I have in the past and will continue in future to appreciate the camaraderie of my fellow cricketers from across the globe and will always respect and honour them on and off the field."
South African media reported South African team manager Mohammed Moosajee as saying that the ICC and the match officials had "noted the alleged incident" and that the matter was in the hands of the ICC.
There was no immediate comment from the ICC. In the post-match presentation, man of the match Phehlukwayo seemed relaxed about having been the target of several comments by Pakistan players. "It was good chat," he said.