Teenager Adam Le Fondre's second-half wonder-strike capped a deserved victory for Stockport at Edgeley Park.
On-loan David Poole got the ball rolling for the hosts when he followed up Tes Bramble's parried shot and slotted past Bees keeper Lee Harrison.
Jason Taylor, Adam Proudlock and Poole all then missed decent chances to double the home side's lead.
But Le Fondre sealed the win with a spectacular overhead kick following Anthony Charles' poor defensive header.
Stockport: Ruddy, Williams, Clare, Owen, Griffin, Poole (Briggs 77), Taylor, Dinning, Proudlock (Robinson 54), Le Fondre, Bramble (Dickinson 77).
Subs Not Used: Spencer, Malcolm.
Booked: Clare, Dinning.
Goals: Poole 31, Le Fondre 51.
Barnet: Harrison (Flitney 62), Hendon, Warhurst, Charles, Nicolau, Hessenthaler, Bailey, Sinclair, Graham (Cogan 66), Kandol, Hatch (Vieira 66).
Subs Not Used: Devera, Grazioli.
Booked: Warhurst, Harrison, Hessenthaler, Nicolau, Charles.
Att: 4,133.
Ref: K Friend (Leicestershire).