Chris Hargreaves and substitute Jay Tabb scored the goals as Brentford reached round four of the FA Cup at Luton's expense.
Hargreaves fired home in the 71st minute and although Luton pushed for an equaliser they were caught out when Tabb sealed the win with two minutes remaining.
With Brentford stringing five across the middle, the game started with a fierce midfield battle that saw Deon Burton fire a 20-yard effort well over in the fifth minute and Steve Howard hit a left-footed snapshot just wide from 15 yards in the seventh minute after Sol Davis' long free-kick.
After a scrappy opening, Rowan Vine lit up proceedings in the 23rd minute when he raced on to Howard's flick-on, bundled his way past Jamie Lawrence then turned Scott Fitzgerald, but saw his left-foot shot from ten yards pushed around the post by Stuart Nelson.
From the resulting Paul Underwood corner, Howard volleyed home amidst a huddle of players, but the goal was disallowed for a foul on Michael Turner.
Howard almost scored legitimately eight minutes before the break when he found space in the area to connect with Robinson's inswinging free-kick, but he put his header wide from eight yards.
The half ended with an ugly melee between the players after Ben May went in late on Marlon Beresford and Davis was booked after the shoving that ensued.
Steve Robinson hit a 25-yard effort just over the bar for Luton in the 58th minute and Brentford responded with May setting up Burton for a 20-yard strike four minutes later that Beresford saved low to his right.
The visitors took the lead in the 71st minute when Curtis Davies slipped when dealing with a routine long ball down the left and Isaiah Rankin ran in on goal but saw his shot blocked by Chris Coyne. The ball bounced for Chris Hargreaves to rifle home left-footed into the top corner from 16 yards.
Tabb ran on to Rankin's pass at the end and steered home left-footed past Beresford from the edge of the penalty area to seal the victory.