It was the only men's match to be completed on a day when play was continually interrupted by heavy showers at Flushing Meadows.
Former US Open champions Andy Roddick and Juan Martin del Potro were locked in a first-set tie-break, defending champion Novak Djokovic was two games up early in the opening set against Stanislas Wawrinka and Janko Tipsarevic was 5-2 ahead against Philipp Kohlschreiber when organisers eventually called off play in the evening session.
Ferrer, the last Spaniard left in the men's field, withstood two rain delays before completing a straight-sets win that took less than three hours of court time but stretched from dayside into night at the National Tennis Center.
The victory improved Ferrer's career record to 8-1 over the 13th-seeded Gasquet.
"We almost had to start over two times in the match," said the 30-year-old Ferrer, a five-times winner this season, who moved up in the seedings following the withdrawal of compatriot Rafa Nadal due to injury. "It took a lot of focus."
It also took a lot of effort in the final game for Ferrer to end the match, clinching his spot in the last eight on his fifth match point when Gasquet sent a backhand long in the fourth-round match in Louis Armstrong Stadium.
The victory made Ferrer the second Spaniard after Nadal to reach at least the quarter-finals of all four Grand Slam events in a season since tennis went professional in 1968.
"I'm very happy for that. This season was the best of all my career. I've played consistent all the year," said the Spaniard, who is aiming to reach his first Grand Slam final.
The match was close in nearly every statistical category, but it was Ferrer who won the big points, taking advantage of five of 12 break point chances while fighting off eight of Gasquet's 11 opportunities to break serve.
"I think I have luck in important moments," said Ferrer, who faced three set points in the second set.
"The first round with (South African Kevin) Anderson I had also three set points down. With (Dutchman Igor) Sijsling in second round also the same, no?"
Despite those threats, Ferrer has reached the last eight without the loss of a set and will meet either eighth seed Tipsarevic of Serbia or 19th-seeded German Kohlschreiber in the quarter-finals.
The winners of the other two outstanding matches will complete the last-eight line-up.
- Philipp Kohlschreiber