Danks ripped the first offering from A's reliever Pat Neshek (1-1) to provide the dramatic victory for Chicago (61-50). It was the club's fourth solo home run of the night.
"That was my first walk-off home run in my life and it feels good, I got to tell you," Danks said. "Being late in the game especially, bottom of the ninth, it's something that everybody dreams about their whole life. Right before that I saw myself doing it and it was just one of those things. It was just awesome."
A.J. Pierzynski, Alexei Ramirez and Dayan Viciedo erased an early 3-0 deficit with home runs off Oakland starter Brandon McCarthy, who began his career with the White Sox during their World Series championship season in 2005.
"It was a good win, obviously coming back after falling down early and we found a way to battle back," said Pierzynski, whose 22 home runs are the most by a Chicago catcher since Carlton Fisk hit 23 in 1987. "Luckily, we hit four home runs, otherwise we didn't do much offensively."
White Sox right-hander Gavin Floyd continued a trend of getting into early trouble, then gutting out an effective performance to preserve the bullpen. That allowed his teammates the opportunity to chip away at that three-run deficit after two innings.
Floyd pitched six-plus innings, allowing three runs on five hits with three walks and five strikeouts. Although Oakland (60-52) had at least one runner on base in every inning against Floyd, he only allowed two runners into scoring position after a two-run home run by Brandon Moss gave the A's a 3-0 lead with no outs in the second inning.
"It's been like that the past couple games," Floyd said of his early troubles. "But I've got to go out there and compete, and keep my team in the game. When it happens I'm going to battle my butt off to put up zeros."
The bullpen followed with another strong outing as four pitchers combined to get the final nine outs, which included five strikeouts. A ninth-inning walk by eventual winner Brett Myers (1-1) was the only blemish by the relievers.
In the past 17 games, the White Sox bullpen has a 1.36 ERA, having allowed only seven runs in 46 1/3 innings.
But the star of the night was Danks. Injuries have given Danks the opportunity to start four consecutive games. The team learned earlier in the day that Paul Konerko was placed on the seven-day concussion disabled list.
Regardless of being a starter or late-inning replacement, Danks said he realizes no role is unimportant on this White Sox team.
"When I wasn't playing every day, I was always ready to get in there before the seventh inning," Danks said. "I knew that was going to be my role when I got here. If somebody needed a day or somebody goes down, fill in and do it to the best of my ability. I feel like I did pretty good tonight."
Tempers flared briefly in the sixth when McCarthy hit Pierzynski with a 92-mph sinker on a 2-0 count. Pierzynski stared at McCarthy as he began his trot to first while home-plate umpire Tony Randazzo warned both benches. That came after Floyd hit Yoenis Cespedes with a pitch in the fifth inning.