A 76th minute winner from the head of Dean Windass was enough for Bradford City to go home to Yorkshire with maximum points.
The Bantams now head off on their Carling Cup adventure in good heart after two league wins on the spin.
After just seven minutes Stockport were almost celebrating a very rare goal from full-back Danny Adams but his low drive struck the base of the far post.
Collin Todd's side soon settled though and before the 15 minute mark Dele Adebola had planted a header just wide and Steve Schumacher drilled in a shot which was well saved by Neil Cutler.
Stockport showed more resilience towards the end of the first half however, and Luke Beckett came close to his fifth goal of the season only to fire his shot over the bar.
County had a great chance to open the scoring on the stroke of half time, but Rickie Lambert thumped his 20-yard free-kick into the Bradford wall.
Both sides continued to trade chance for chance after the break before Ben Muirhead went close for Bradford with a shot that was well saved by Cutler.
Beckett replied for County with a curling shot which almost hit the target.
The deadlock was almost broken on 65 minutes but Stockport youngster Ashley Williams saw his close-range shot bravely blocked on the line by David Wetherall.
The Bantams' breakthrough finally came with just 14 minutes to go when the match looked to have 0-0 written all over it.