Brentford battled for a first home win in six weeks in a hard-fought contest with managerless Hartlepool.
Gary Alexander nearly broke the deadlock for the Bees before half time but his point-blank header was saved.
Pools keeper Scott Flinders was at fault when Niall McGinn's lob slipped through his hands with 10 minutes left.
Sam Collins' deflected shot equalised within minutes but soon after Toumani Diagouraga was brought down and Alexander scored from the penalty spot.
VIEWS FROM THE DRESSING ROOM
Brentford manager Uwe Rosler told BBC London 94.9:
"It was a proper hard working performance.
"Second half the team showed a big improvement. The tempo we had and pressure we put on them was good.
"Lady luck was a bit on our side today but we worked very hard for those margins."
Hartlepool caretaker boss Micky Barron tells BBC Tees:
"Tony [Sweeney] is upset, he's adamant it wasn't a foul, he says he got the ball.
"The players are saying there were that many people around, it was difficult to tell, I couldn't tell you which player had gone over.
"When you see people genuinely upset like that you can tell he has won the ball and he's really disappointed the penalty has been given."