Fellow Canadian Vasek Pospisil is out of the tournament following a loss in his debut match.
Raonic, seeded 12th, hung Sock out to dry in their second-round match, ending with his 14th ace after 86 minutes. The Thornhill, Ont., native broke once while allowing Sock few chances to take an initiative.
"It was a decent first match, a bit windy," said Raonic. "It was a good chance to find my rhythm.
"The further I get into a tournament the more I start to cut my margin for error. I think in the next match (against Spain's Guillermo Garcia-Lopez) I can start to take more chances."
Raonic's victory marked his third straight appearance in a Miami third round, the best he has done so far. A year ago, he was forced to withdraw with an injury before facing American Sam Querrey.
Toronto doubles veteran Daniel Nestor and Serbian partner Nenad Zimonjic took an opening win over Andy Murray's elder brother Jamie Murray and John Peers, beating the pair 6-4, 7-5 in the first round.
Pospisil failed to end a two-month losing streak on the ATP as the Vancouver native fell to Slovenian Aljaz Bedene, but came away with a positive attitude on his progress after recent back pain.
The 27th seeded Pospisil was beaten in a first-time meeting with Bedene 7-6 (7-5), 5-7, 6-3. Pospisil, only recently recovered from pains which began late in the previous season, won the opening set but could not maintain momentum.
He had never played the Masters 1000 event in South Florida.
Pospisil went down in just under two and a half hours, and has not won a match since the Australian Open in mid-January when he beat Matthew Ebden in the second round.
"Overall it was positive for me," said Pospisil, "The back felt almost 100 per cent. It was the first time I felt I could compete and have a chance of winning a match."
Pospisil ended with a modest seven aces against eight for No. 119 Bedene, with Pospisil never earning a break point while losing serve twice.
"It was a tough match. He played well, it was very physical," Pospisil said. "My level fell a bit at the end when I needed to hang tough, but it's a good feeling knowing that you can compete.
"I felt that I could almost move up to my standards. It's a much better feeling. I'm disappointed but I did play well, especially on serve and from the back of the court."