Hudson pitched seven effective innings and the Diamondbacks ended the San Francisco Giants' four-game winning streak with a 3-1 victory.
Miguel Montero, Stephen Drew and Kelly Johnson each drove in a run for Arizona, which snapped a four-game skid. Hudson settled down after Freddy Sanchez's first-inning homer, allowing just four more hits.
Barry Zito (8-12) was almost as good as Hudson, working six solid innings, but it wasn't enough for San Francisco, which dropped two games back of NL West-leading San Diego.
"We didn't hit many balls hard, but when we did, they caught them," Giants manager Bruce Bochy said. "We got a good pitching effort. I thought Zito threw the ball well and gave us a chance. We just couldn't get the bats going."
San Francisco opens a key four-game series at San Diego on Thursday night.
Drew tripled and scored on Johnson's one-out single in the third, giving Arizona a 2-1 lead, and added a run-scoring single of his own in the seventh.
"Just trying to get a good pitch to hit," Drew said of his triple. "He was throwing his offspeed well and I got another changeup right there and just had a good swing at it."
Montero doubled in Chris Young with two out in the second. The catcher also walked and scored on Drew's two-out hit.
"The key to the game is we scored on two walks," Diamondbacks manager Kirk Gibson said.
Zito yielded just four hits and struck out seven, but lost his eighth consecutive decision. The left-hander has a 5.49 ERA in 11 appearances since his last victory July 16 against the New York Mets.
Hudson (5-1) retired 10 straight before Pablo Sandoval singled with one out in the seventh. The Giants went on to put runners on first and third in that inning but Hudson got pinch-hitter Travis Ishikawa to ground out to end the threat.
"We knew we were going to let him go through it," Gibson said of Hudson's jam. "We feel he's well-equipped for that. ... He had a very good demeanor to do that and that's the way he conducts his business out there."
Gibson, the interim manager, said he would like to be back as the permanent manager of the club next season. "I certainly feel that I can take the organization where they need to go," he said. ... Arizona 3B Mark Reynolds returned to the starting lineup for the first time since Sunday, when he aggravated a hand injury and had to leave the game. Reynolds entered Tuesday's game as a pinch hitter. ... Arizona players served lunch at a local homeless shelter before Wednesday's game, and Gibson said he encourages volunteering. "If I'm back here next year, we'll do more things like that," Gibson said. "It shouldn't be something that's hard to do for any of us." ... Arizona RHP Brandon Webb threw between 50 and 60 pitches in a batting cage, and came way feeling good and encouraged. He's coming back from shoulder surgery and hopes to pitch at least once in a game before the season ends.