The 21-year-old Rybakina beat Williams 6-3, 7-5 in just her seventh Grand Slam appearance. Williams, who hasn't advanced past the fourth round in Paris since finishing as the runner-up in 2016, ended up with 19 unforced errors and only 15 winners in the defeat.
"I'm so close. There is literally a point here, a point there, that could change the whole course of the match," Williams said. "I'm not winning those points. That, like, literally could just change everything."
Rybakina will next face Anastasia Pavlyuchenkova for a spot in the semifinals. Pavlyuchenkova advanced to the next round with a 5-7, 6-3, 6-2 win over two-time Australian Open champion and No. 15 seed Victoria Azarenka earlier in the day.
The other quarterfinal matchup on that side of the women's draw will be Paula Badosa against Tamara Zidansek. Badosa defeated Marketa Vondrousova 6-4, 3-6, 6-2 to advance, while the unseeded Zidansek beat Sorana Cirstea in straight sets.
On the men's side, No. 2 seed Daniil Medvedev beat Cristian Garin 6-2, 6-1, 7-5 Sunday to reach the French Open quarterfinals.
Medvedev, who arrived in Paris with a career record of 0-4 at the tournament, overcame a right elbow ailment to defeat Garin in straight sets. The Russian will play fifth-seeded Stefanos Tsitsipas in the next round.
Tsitsipas reached the quarterfinals for the second consecutive year after his 6-3, 6-2, 7-5 win over No. 12 seed Pablo Carreno Busta. Medvedev holds a 6-1 record in his career against Tsitsipas.
Alejandro Davidovich Fokina, meanwhile, advanced to his first Grand Slam quarterfinal with a 6-4, 6-4, 4-6, 6-4 victory over Federico Delbonis. Davidovich Fokina will challenge No. 6 seed Alexander Zverev, who clinched a berth in the quarterfinals by eliminating Kei Nishikori 6-4, 6-1, 6-1.
Zverev, who was the runner-up at last year's U.S. Open, is attempting to win his first Grand Slam title.
Earlier Sunday, 20-time Grand Slam champion Roger Federer withdrew from the French Open, citing his recent knee surgeries.
"After two knee surgeries and over a year of rehabilitation it's important that I listen to my body and make sure I don't push myself too quickly on my road to recovery," Federer said in a statement. "I am thrilled to have gotten three matches under my belt. There is no greater feeling than being back on the court."
The 39-year-old Federer was competing in his first major tournament since the 2020 Australian Open. He was scheduled to face No. 9 seed Matteo Berrettini for a spot in the quarterfinals before pulling out of the event.