The match, lasting 3 hours, 13 minutes, featured 20 service breaks, with neither player finding much confidence on their service games.
The 37-year-old Williams dropped her serve nine times, while the 20-year-old French Open champion conceded serve 11 times.
"I don't know if there was any luck for me tonight, I just had to work for every point,'' the fifth-seeded Williams said. "It's not easy to lose the first match, and both of us were in the same situation. What else can you do but fight to live another day?''