Spaniard Garbine Muguruza, the 14th seed, ended Kerber's tournament and the German's reign as No. 1 in the world with a 4-6, 6-4, 6-4 victory in the Round of 16 in London on Monday.
The 10th-seeded Williams is back in the Wimbledon quarterfinals for the second straight year as the American took a 6-3, 6-2 commanding win over 19-year-old Ana Konjuh of Croatia on Centre Court.
"Winning never gets old at any stage in your career, ever, ever," Williams said afterward. "I think I'm playing pretty solid. For me, it's about getting through the round. You're not going to play perfect every round. I would like to play, you know, in straight sets every round. That would be great. If not, all that matters is you win."
With Kerber's loss, either Simona Halep of Romania or Karolina Pliskova of the Czech Republic will take over as the top-ranked player after the tournament.
The second-seeded Halep advanced with a 7-6 (3), 6-2 victory over former No. 1 Victoria Azarenka of Belarus.
Halep reached the semifinals at the All England Club in 2014 and played in the quarterfinals last year. She just needs to reach the semifinals to secure the No. 1 ranking.
Muguruza dictated proceedings in the two hour, 18-minute encounter as she struck 55 winners to Kerber's 27 while also striking 50 unforced errors, 40 more than her opponent committed.
In addition, Muguruza was successful on over 60 percent of the points when she went to the net, winning 35 of 54 total.
"When you have somebody that it's so, you know, physically strong, so solid, the more you win free points or make it shorter, it's better," Muguruza said after the match. "It's also part of my game. ... I like to don't wait 20 shots. I go for it. Today I think was a key to make short points sometimes."
With her fifth straight loss to Muguruza, Kerber will see her reign at No.1 end after 34 weeks.
"It was for sure the best match for a long time for me," Kerber said in defeat. "When I came here, I was telling myself, I was practicing good after Paris. For me, I'm still looking for the next months, next weeks. I think I'm again on a good way to playing again tennis, yeah, on a high level.
"I think we both play a good match, but at the end, I think just two points that decided the match. Of course I'm disappointed that I lost the match, because I was really playing good. Just one can win, and that was not me today."
Williams, who last won the Grand Slam grass-court event in 2008, powered through to her 13th Wimbledon quarterfinal, hitting seven aces and winning 31 of 36 first-serve points against No. 27 seed Konjuh.
Williams, the only remaining former champion left, will now take on the reigning French Open champion Jelena Ostapenko in the quarterfinals. The 13th-seeded Latvian upset No. 4 seed Elina Svitolina of Ukraine 6-3, 7-6 (6) earlier in the day to win her 11th straight Grand Slam match.
American CoCo Vandeweghe, the 24th seed, reached her second Grand Slam quarterfinal of 2017 with a 7-6 (4), 6-4 win over former No. 1 and fifth-seeded Caroline Wozniacki of Denmark. Wozniacki has not reached the quarterfinals at the All England Club in 11 appearances.
Sixth-seeded Johanna Konta of Britain fashioned a 7-6 (3), 4-6, 6-4 win over No. 21 seed Caroline Garcia of France to end a 33-year drought since Wimbledon had home representation in the last eight of the women's singles. Konta will next face Halep.
Earlier Monday, No. 7 seed Svetlana Kuznetsova became the first player to reach the quarterfinals as the two-time Grand Slam champion from Russia beat ninth-seeded Agnieszka Radwanska of Poland 6-2, 6-4.
Muguruza and Kuznetsova will meet in the next round.
In a fourth-round match of unseeds, Magdalena Rybarikova of Slovakia eliminated Petra Martic of Croatia 6-4, 2-6, 6-3 to reach her first Wimbledon quarterfinal.