Striker Lee Novak fired in from a Gary Roberts’ cross on 85 minutes only for Mark Phillips to clear the goal-bound effort off the line as a midfield scrap developed into a pulsating finish.
Earlier, Huddersfield midfielder Antony Kay had come closest to breaking the deadlock with a 30-yard dipping volley which Bees keeper Lewis Price did well to tip over on eight minutes.
Town started the game as the Football League’s highest scorers with 17 goals in six matches, but Brentford restricted the Terriers to long-range efforts until Novak struck.
Roberts, Kay, Theo Robinson and Danny Drinkwater all fired in shots from distance without testing Price.
Brentford’s stifling game meant they showed little attacking threat before the break, but they should have won it against the run of play on 70 minutes. Unmarked Cleveland Taylor miscued a close-range shot wide after Steve Kabba beat Town’s offside trap down the left and swung over a low cross.