After women's champion Victoria Azarenka and Caroline Wozniacki safely made it through, Federer took to centre court with the mercury hitting 40 Celsius (104 Fahrenheit).
Despite the stifling conditions, the Swiss star, playing a record 57th consecutive Grand Slam tournament, eased past Australia's James Duckworth 6-4, 6-4, 6-2 in an hour and 46 minutes.
Federer, 32, said it was great start to his Grand Slam partnership with Stefan Edberg, the six-time major-winner who has joined him as a coach.
"It's great fun to be playing in front of him and it's been a dream come true for me," Federer said of the Swede, who was watching from the stands.
"I used to watch his matches and get inspired to play this great game so to have him in my corner through the year and this tournament is very special and I can't be thankful enough."
Azarenka made hard going of her 7-6 (7/2), 6-2 win over 91st-ranked Johanna Larsson, while 10th seed Wozniacki beat Spain's Lourdes Dominguez Lino for the loss of just two games.
But the day's dominant theme was the intense heat, which soared to 41.6 Celsius (106.9 Fahrenheit) by late afternoon and hotter on the rubberised blue courts.
Canada's Dancevic needed medical attention after appearing to faint and Chinese player Peng Shuai also had treatment when she fell ill during her defeat to Japan's Kurumi Nara.
During his loss to Milos Raonic, Daniel Gimeno-Traver rushed to the rescue of a ball boy who collapsed on court.
"It felt pretty hot, like you're dancing in a frying pan or something like that," Azarenka said. "I don't think anybody wants to go outdoors right now."
France's Jo-Wilfried Tsonga went through in straight sets against Filippo Volandri but Japan's Kei Nishikori, a quarter-finalist in 2012, took five to subdue Australia's Marinko Matosevic.
Bulgaria's Grigor Dimitrov beat American player Bradley Klahn but 13th seed John Isner was forced to retire with an ankle injury while playing Slovakia's Martin Klizan.
Wozniacki, flashing her eight-carat diamond engagement ring from golfer fiance Rory McIlroy, said she was ready for a new start after hooking up with Maria Sharapova's ex-coach Thomas Hogstedt.
"I have achieved so much in my career already," said the former world number one, still looking for her first Grand Slam title. "But at the same time, when I go on court and when I play tournaments I want to win.
"For me right now I try to focus on the Grand Slams. It's tough, it's never easy. You have to win seven matches. There's always going to be some tricky opponents along the way."
World number one Rafael Nadal and Russian star Sharapova will miss the worst of the day's heat when they headline the evening session against local hope Bernard Tomic and American Bethanie Mattek-Sands.
Temperatures are forecast to stay high this week in what could be one of Melbourne's most severe heatwaves on record.