Almagro, who ended the singles career of retiring friend and Spanish compatriot Juan Carlos Ferrero by beating the former world No. 1 in the first round, broke unseeded American Querrey’s serve three times in the final set and will play top seed David Ferrer for a place in today’s semis.
Ferrer, who won the Valencia title in 2008 and 2010, wasted little time in disposing of Albert Ramos in an all-Spanish second-round match, prevailing 6-4, 6-2.
The winner of the Almagro-Ferrer clash will face either seventh seed Marin Cilic, who has a slim chance of making it to London, or qualifier Ivan Dodig, both Croatians who were already through to the last eight of the indoor hard court event.
On the other side of the draw, defending champion Marcel Granollers, whose triumph last year was only his third career singles title, made it through to the quarter-finals when he came from a set down to beat Frenchman Gilles Simon 6-7 6-3 6-2.
Granollers will play Alexandr Dolgopolov after the Ukrainian saw off Gilles Muller of Luxembourg 6-4, 6-4.
The winner will face either Austria’s Jurgen Melzer, who beat Xavier Malisse 7-5, 6-2, or Malisse’s Belgian compatriot David Goffin in the last four.