While the first set was close, the drama really unfolded in the 58-minute second set, with Petkovic coming within two points of going to a third at 4-5, 0-30, but eventually closing Mattek-Sands out, 64 75. It was a little bit of revenge for Petkovic, who had dropped the pair's last two encounters.
The German's reward for the victory is a second round clash with No.1 seed Serena Williams, who got a first round bye. Williams beat Petkovic in their only previous meeting, though it went to three sets.
"It will be a great challenge for me right before a Slam," Petkovic said of the looming clash. "I think I couldn't have a better preparation than playing against Serena. I'm very excited actually because she's always been my idol growing up and I admire her for so many things, I have so much respect for her as a player and a person. I think it's going to be a great challenge and I'm really looking forward to it."
The only seeded player in action was No.7 seed Sabine Lisicki, who put on a serving display - firing seven aces and fighting off all three break points she faced - to beat Magdalena Rybarikova, 63 64.
"It was 37 degrees Celsius, so it was very hot, but welcome to Australia!" Lisicki said. "After two and a half months off from tournaments it's tough to play your first match, but I'm happy to get through."
One player who won't be playing her first round match anymore is Caroline Wozniacki, who had to withdraw from the tournament due to a right shoulder injury. She would have been the No.6 seed.
"I felt it after one practice, and I feel it's important that I really get 100% and make sure it doesn't get worse," Wozniacki said. "It's obviously very disappointing because I really look forward to playing here and starting the year off here, but with some good treatment I should be ready to play in Sydney."
Heather Watson, Ashleigh Barty, Alla Kudryavtseva and Alexandra Panova secured spots in the main draw with wins in the final round of qualies. Barty had by far the most dramatic win of the four, rallying from 5-2 down in the third set - and facing five match points down 5-4 - to beat Kiki Bertens, 26 63 75.
"It's great to come back from a few match points down. The last couple times I've been on the wrong end of it," Barty said. "It's awesome playing at home. It's great to have the crowd behind you. It makes it a lot easier to come back in a match like that when the crowd is behind you. I love playing here."