Huddersfield narrowly saw off Stevenage thanks to John Mousinho's last-minute penalty miss for the visitors.
Gary Roberts put the Terriers ahead before the interval with a cool finish.
Mousinho set up Scott Laird to lash Boro level after the break, only for Lee Novak to put the hosts back in front after Anton Robinson hit the post.
With time running out Stevenage were handed a lifeline when Antony Kay was adjudged to have fouled Byron Harrison but Mousinho blasted his penalty over.
The game ended in controversy as both benches were involved in ugly scenes after the final whistle.
Huddersfield, who are third, are now unbeaten in 37 league games.