The Swiss outplayed 49th-ranked Coric 5-7, 6-4, 6-4 to surpass his 16-match winning streak.
The twenty-time grand slam champion will next face Argentina's Juan Martin del Potro, who defeated Canada's Milos Raonic 6-2, 6-3.
The two have met four times last year. Federer claimed three of those matches, while Del Potro got the better of him in US Open quarter-finals.
"Yeah, we have had a lot of close matches. Big matches, close matches," the 36-year-old recalled of his rivalry with Del Potro.
"I think we have an interesting matchup. We both know what the other is trying to do, and we try to stop the other person from doing it. But it's hard when [one of us] is in full flight. It's basically an arm wrestle the whole time, and I think we enjoy that," he added.
It will be their 25th meeting overall at the BNP Paribas Open, where Federer will be searching for a record sixth title at Indian Wells. (ANI)