Dempsey drilled the ball into the net after just 32 seconds at the Dunas arena before Andre Ayew finally gave Ghana reward for their second half pressure with an equalizer seven minutes from the end of a physical and often testy match.
The contest looked destined for a draw until substitute defender Brooks rose to head Graham Zusi's corner firmly into the back of the net and give the United States revenge over the team that ended their participation in the last two World Cups.
Juergen Klinsmann's side will now go onto their next match against Portugal, beaten 4-0 by Germany in the Group G opener earlier on Monday, with renewed belief that they can reach the last 16.
"There are things we can improve on but we got the three points we badly wanted," Klinsmann told U.S. television. "Ghana is a good team, they know how to grind the game. It was what we expected."
The Black Stars, quarter-finalists in South Africa four years ago, who will rue their profligacy in front of goal and now face a huge task if they are to get past the group stage for the third straight tournament.
Fears many had about the fragility of the Ghanaian defense were confirmed when Dempsey struck before many of the fans had got back in their seats after the anthems.
Jermaine Jones played the ball into his path from the touchline and the striker stepped inside central defender John Boye to slot it inside the far post with his left foot and become the first American to score in three World Cups.
Ghana settled and showed that at the other end of the pitch they were an altogether different proposition with right winger Christian Atsu looking particularly dangerous in all but the final ball.
Captain Asamoah Gyan squandered a string of opportunities for an equalizer but he was not alone with Jordan Ayew, son of Abedi Pele, passing up an excellent chance just before halftime.
It was left to his brother Andre to get Ghana back into the match in the 83rd minute, latching on to his skipper's neat back flick and lashing the ball into the net with the outside of his left foot in almost the same position Dempsey had scored from.
The Americans would not be denied, however, and the unheralded Brooks proved the unlikely winner to send the red, white and blue half of the stadium into raptures.
Image: Clint Dempsey celebrates after scoring
Photograph: Laurence Griffiths/Getty Images
FIFA World Cup Fan Zone: Dutch gain; pain for Spain and much more...
Points Table: Football World Cup 2014
World Cup: Klinsmann believes Beckerman to be US's main man
World Cup chit-chat: Brazil's Fred denies diving claims to win penalty
Iran, Nigeria listless in first draw at Brazil World Cup