After dropping just two games in his second-round opener against Czech qualifier Dalibor Svrcina, Sinner was caught napping to drop his serve in the opening game.
He responded with confidence against a potentially tricky opponent known for producing winners.
Sinner quickly recouped the break and grabbed another in the eighth game.
"It's a very tough second match for me," Sinner said. "He's a very high-quality player ... he had great wins in the past so I'm very happy about today's performance."
With one set in his pocket, Sinner was in full control in the second, opening with a break on the way to a 5-2 lead and closing it out with a love game.
"I tried to stay solid on the baseline but also a bit more aggressive in the second set," Sinner said. "It was a tough start for me with a break down but I'm happy how I reacted."
Sinner faces the 19-year-old Fonseca for a place in the quarter-finals.
Fonseca, who saved two match points in his second-round victory over Karen Khachanov, beat another seeded player, American Tommy Paul, 6-2, 6-3.
Fonseca brought the heat, displaying thunderous groundstrokes as he reached the fourth round of a Masters 1000 for the first time.
He said he was eager for the chance to test himself against four-time major winner Sinner.
"We tennis players, we look to playing against top players so it's going to be a pleasure - and hopefully I can get the win," he said.
Zverev sees off tricky Nakashima test
Fourth-seeded German Alexander Zverev had to go the distance to reach the fourth round, holding off a determined Brandon Nakashima 7-6(2), 5-7, 6-4.
Zverev didn't have a break point against the 30th-ranked opponent until the third set. He missed his first two opportunities before finally making one count, breaking Nakashima in the final game to seal the victory.
"He has an incredible serve, and you don't think about that," Zverev said of Nakashima, who fired 17 aces to the German's 15. "His placement on serve is probably the best in the world.
"What he's lacking in power, he's definitely got in placement. I was not having any chances to break him for the first two and a half sets, and the only chance I kind of had, I used it in the end.
"Definitely happy to get the win because that was a difficult match," Zverev said.
The German gained the upper hand in a close-run contest with a dominant first-set tiebreaker, but the American converted his fifth break chance for a 6-5 lead in the second and levelled the match with a love game.
Zverev improved to 5-0 against Nakashima, a 24-year-old Southern California native who remembers watching Novak Djokovic and Roger Federer play Indian Wells as a youngster.
He'll face either 15th-seeded Italian Flavio Cobolli or American Frances Tiafoe for a place in the quarter-finals.
Rising US talent Learner Tien knocked off eighth-seeded compatriot Ben Shelton 7-6(3), 4-6, 6-3.
Tien peppered big-serving Shelton with 15 aces while Shelton, who appeared to be feeling the effects of the illness that slowed him in a second-round win over Reilly Opelka, produced just eight.
"It's great," Tien said of lining up a last-16 shot at 18th-seeded Spaniard Alejandro Davidovich Fokina - a 6-2, 4-6, 6-2 winner over 12th seed Jakub Mensik.
But he knew Shelton wasn't at his best.
"I don't think he's been feeling great all week, but he's an amazing competitor and he came out and gave it his all," Tien said. "So I just want to say, huge props to him."
