Middlesbrough manager Jonathan Woodgate was left frustrated after his side’s late defeat.
Ollie Watkins struck three minutes from time to grab a 3-2 victory – Brentford’s first home win over Boro since 1938.
Boro levelled through Lewis Wing and Ashley Fletcher after Julian Jeanvier and Bryan Mbeumo twice gave the hosts the lead.
But Watkins’ 20th goal of the campaign sealed the win and kept the Bees hot on the heels of the top two.
“We had a lot of control for part of the game and that’s encouraging, but they are a very good side,” said Woodgate after just his side’s second defeat in nine league games.
“For much of the game we matched them, so I’m very disappointed not to get a point from it, but you can’t give good sides like Brentford a head start.”
Woodgate bemoaned his side’s defending from set-pieces, adding: “You can’t defend like that, especially here. The second goal was a big deflection and I need to see the third again.
“If I have to take positives out of it, they would be that we kept on playing and trying to do the right things and showed a lot of character to get back into the game when we went behind.”
Woodgate singled out centre-back debutant Harold Moukoudi, a transfer window signing from French club St Etienne, as a pivotal figure in Boro’s end-of-season run-in.
He said: “He’s a very good player, good on the ball, quick and strong and he’s going to be a very good player in the future for us.”
Brentford: Raya, Dalsgaard, Jeanvier, Pinnock, Henry, Jensen (Marcondes 73), Norgaard, Da Silva, Mbeumo (Roerslev Rasmussen 90), Watkins, Benrahma. Unused substitutes: Valencia, Fosu, Baptiste, Daniels, Luca Racic.
Middlesbrough: Pears, Howson, Moukoudi, Fry, Coulson, McNair, Saville, Tavernier (Nmecha 75), Wing, Johnson (Assombalonga 63), Fletcher (Gestede 86). Unused substitutes: Morrison, Mejias, Clayton, Spence.
Referee: P Bankes (Merseyside).