Goals in each half from Liam Davis and Michael Uwezu handed the Cobblers a priceless win in an ill-tempered clash, but it was a bad day all-round for promotion-chasing Stevenage, who saw Luke Foster and John Mousinho dismissed.
Davis gave Northampton the perfect start, firing home in the third minute through a crowded area after a Michael Jacobs' corner was only partially cleared.
But Stevenage were reduced to 10 men in the 38th minute when Foster received a straight red card for a challenge on Seth Nana Ofori-Twumasi and Northampton took full advantage to control the second half.
The hosts doubled their advantage in the 59th minute when Uwezu followed up to slot home the rebound from Kevin Thornton's shot.
With six minutes remaining, Mousinho received his marching orders for a late challenge on Jacobs to end Stevenage's hopes of a late comeback.