London 2012 silver medallist Dempsey ended the first day of competition seventh, but had continued to progress throughout the regatta and headed into the penultimate day of action in second.
But the 32-year-old will go into the medal race as the man to beat after finishes of first and fourth has him nine points ahead of London 2012 champion Dorian Van Rijsselberge of Holland with just the medal race left to go.
Dempsey made the most of Rijsselberge's slip up as the Dutchman finished 27th, which he discarded, and 16th, meaning the Brit could become the first sailor to win two RS:X world titles, having already finished top of the pile in Weymouth in 2009.
"The wind was weaker, which makes things slower. The wind was shifting again, very demanding tactically. For the medal race, is good to do the right thing at the right time, without much planning", said Dempsey.
With the top ten sailors battling it out in the medal race Dempsey will not be joined by compatriots Elliot Carney and Tom Soares as they finished the regatta in 19th and 31st respectively.
And Great Britain could leave Brazil with two medals to show for their efforts with Bryony Shaw heading into the women's medal race in third.
However, the gold medal is out of Shaw's reach as Lee-El Korsiz of Israel wrapped up her third consecutive title with a day to spare.
Shaw heads into the medal race currently occupying third spot, just three points behind Israel's Maayan Davidovich and 11 ahead of fourth-placed Charline Picon of Spain.
Once again Shaw will be Great Britain's only representative in the women's medal race, with Izzy Hamilton and Claudia Carney ending the regatta in 15th and 31st respectively.
- Sports & Recreation