SEATTLE (AP) -- All night, Steve Sarkisian felt if he could just get the ball past the first, stout wave of Stanford's defense, the opportunity was there for Washington to make big plays.
It happened only twice and thanks to a stunning defensive effort by the Huskies, it was enough Washington to pull out the upset of the eighth-ranked Cardinal.
''The way we executed in the most critical moments, that's what I'm most proud of those guys for,'' Sarkisian said.
Kasen Williams took a quick screen pass from Keith Price, broke a tackle and the line of scrimmage and raced 35 yards for the go-ahead score with 4:53 left, and Washington rallied from 10 points down to stun No. 8 Stanford 17-13 on Thursday night.
Trailing 13-3 late in the third quarter, the Huskies (3-1, 1-0 Pac-12) got a 61-yard touchdown sprint from running back Bishop Sankey on fourth-and-1 for their first offensive touchdown against an FBS opponent since the first quarter of the opener against San Diego State.
Then Washington put together a nine-play drive that included another fourth-down conversion and was capped by Williams' catch-and-run that gave the Huskies their first lead.
It was Washington's first win over a top 10 ranked opponent since its upset of then-No. 3 USC back in 2009, Steve Sarkisian's first season at Washington. And it was thanks to an inspired defensive effort that was the opposite of a year ago when Stanford (3-1, 1-1) bulldozed the Huskies to the tune of 446 yards rushing and 65 points.
If nothing else, new defensive coordinator Justin Wilcox earned his lofty salary with a unique scheme that stymied Stanford's power attack.
''Against Stanford we know what they were going to do, we knew they were going to try and power the ball down on our throat like they did the last four years and it's worked,'' Washington safety Justin Glenn said. ''But coach Wilcox just told us focus on each play. If something happens, erase it and focus on the next play. We kept battling down after down.''
Washington's student section poured on to the turf of CenturyLink Field after Price took a knee for the final time. It was a crucial win for the Huskies in the first game of a schedule that only gets tougher next week at No. 2 Oregon before returning home to host No. 13 USC.
Price finished 19 of 37 for 177 yards and the touchdown toss to Williams. Sankey had 144 yards on 20 carries after Stanford's defense had allowed just 124 yards rushing combined in the first three games of the season.
But for all the offensive fireworks the Huskies playmakers showed at key times, this victory rested with the Washington defense.
Given extra time to prepare for the Cardinal with a bye last weekend, Wilcox used every minute of it to devise a defensive scheme to slow Stanford's rushing attack.
Most notably, Wilcox regularly had eight or nine defenders near the line of scrimmage, daring Stanford quarterback Josh Nunes to beat them through the air. Stanford went more than 21 minutes of the first half without gaining a first down and Nunes couldn't lead a winning drive in the closing seconds.
Stanford finished with just 235 yards of total offense, the fewest yards allowed by Washington since the 2010 Holiday Bowl against Nebraska. The Cardinal were held without an offensive touchdown for the first time since Oct. 27, 2007 at Oregon State, a 23-6 Stanford loss.
Stanford finished 5 of 18 on third downs and had only one drive of longer than 50 yards. Nunes, the replacement for Andrew Luck, finished 18 of 37 for 170 yards. But the most important factor was Washington's ability to control Stanford running back Stepfan Taylor.
Last year, Taylor ran for 138 yards against Washington and had 153 yards rushing in the upset of then-No. 2 USC on Sept. 15. He finished with 75 yards on 21 carries, none of them longer than 7 yards.
''We didn't play well enough to win,'' Stanford coach David Shaw said. ''We didn't make the throws we needed to make. We didn't make the catches we needed to make. We didn't sustain our blocks in the running game as long as we should have. We got outplayed tonight.''
Washington started its winning drive at the 35 with 8:57 left and converted on fourth-and-1 at their own 44 with Dezden Petty bulling for 2 yards. They eventually got down the Stanford 35 with 5 minutes remaining. That's when Sarkisian called for the quick screen to his star receiver. Williams broke the tackle of Terrence Brown at the line of scrimmage then sprinted down the sideline ahead of safety Ed Reynolds, who caught up enough to knock the ball loose but only after Williams had crossed the goal line.
''I put my head down, I think that's one of my strengths is putting my head down and fighting through tackles and that's what happened on that play,'' Williams said.
Stanford, whose only touchdown came on Trent Murphy's 40-yard interception return in the third quarter, tried to put together one last drive. Ty Montgomery dropped a potential touchdown at the Washington 5,and Stanford eventually faced fourth-and-4 at the Huskies 34 with 2 minutes left. With the defense spread out, Nunes tried to throw a fade route down the sideline to 6-foot-8 tight end Levine Toilolo. But the ball was poorly thrown and Desmond Trufant was in position to intercept the pass at the 8 with 1:46 left. Stanford used its final two timeouts to force third-and-4, but Ben Gardner jumped offside giving the Huskies a first down and the clock ran out.
''I've lost to Stanford every time since I've been here. It's great to be on the other side this time,'' Trufant said.