Hamilton briefly sat atop the time charts after toppling Max Verstappen later in the third session, but his team-mate Bottas sped through seconds later with an unbeatable time, fastest in all three sectors of the Nurburgring track.
Bottas' time was 1 minute 25.269 seconds, beating Hamilton by .256 and Verstappen by .293. Ferrari recovered a little ground after a miserable run of races, with Charles Leclerc qualifying fourth and Sebastian Vettel 11th.
Nico Hulkenberg returned as a late replacement after Racing Point driver Lance Stroll felt unwell. The German previously stood in for Racing Point's other driver, Sergio Perez, in August when Perez tested positive for the coronavirus.
He was in the nearby city of Cologne and hurried to the track upon hearing he was needed to stand in for Stroll. Hulkenberg missed practice and couldn't adapt quickly enough in qualifying as he placed 20th and last.
It will be the first F1 race since 2013 at the Nurburgring and is named the Eifel Grand Prix after a nearby mountain range.