Dallas gave the visitors a surprise lead three minutes before the break with a low shot that went in off the inside of a post.
However, the dismissal of skipper Liam Cooper for a tackle on Gabriel Jesus before the opening period was over appeared to have given the visitors an impossible task.
City predictably dominated the second period but were made to wait until the 76th minute for their equaliser, when Ferran Torres drove home his first Premier League goal since December.
Instead of City completing a triumphant comeback, however, it was Leeds who came up with the winner as Dallas ran on to Ezgjan Alioski’s through ball before sending a shot past Ederson from the edge of the area.
It completed Leeds’ best win since their return to the top flight – and means Manchester United can cut City’s lead at the top to eight points if they win their games in hand against Tottenham and Burnley. City must take 11 points from their remaining six games to guarantee a third league title in four seasons.Leeds’ day to remember
It is a measure of how long Leeds have been outside the top flight that this was only their second league game at Etihad Stadium.
But, as on so many occasions this season, Marcelo Bielsa’s men made a positive impression, even though they were unable to control possession as they did when these sides drew 1-1 at Elland Road earlier in October.
Helder Costa and Tyler Roberts were a threat down the flanks though, so it was not entirely out of the blue when Leeds took the lead.
Joao Cancelo was unusually hesitant having been deployed at right-back and Costa took advantage, providing the pass for Patrick Bamford, who set Dallas up for his precise finish.
It was a shame for Leeds that their captain spoiled all the good work almost immediately with a two-footed lunge.
Cooper was still pleading his innocence as he slowly made his way off the pitch, even though referee Andre Marriner had gone to the monitor before changing his initial yellow card to a red for a tackle that left Jesus needing treatment.
Winning the game at that point seemed a distant prospect for Leeds, even against a City team with seven changes from the one that beat Borussia Dortmund in the Champions League on Tuesday.
Raheem Sterling had already wasted a couple of decent chances for the hosts and, after the break, the contest was more like a game of attack and defence as City piled forward, frequently having all 10 outfield players within 30 yards of the visitors’ goal.
Oleksandr Zinchenko brought a full-length save out of Illan Meslier, Bernardo Silva had a goalbound shot deflected wide and substitute Ilkay Gundogan fired a good chance over before Torres struck.
City did have a warning of what Leeds were capable of when Raphinha broke clear, only to be denied by Ederson’s perfectly executed slide tackle.
However, Leeds had one more attack left in them – and Dallas provided the perfect finish to give his side a third successive Premier League win for the first time since 2002-03, when Terry Venables was in charge.
‘We didn’t stop them from running’ – what they said
Manchester City boss Pep Guardiola told BBC Match of the Day: “We did not create enough for the forwards. It is part of the game.
“In the last 10 minutes they had other chances, they are fast and can do it. When they defend in the way they were doing you have to stop them running and we did not do that.
“We are going to rest and prepare two days for the game in Dortmund and decide on how we are going to play.”
Leeds United boss Marcelo Bielsa told BBC Match of the Day: “The value of the victory increases because it was achieved in a game where we were dominated and demanded character, effort and personality.
“I think we have to link the victory to the spirit of the players. The spirit of all the players added together creates a uniform effort. It’s very difficult to win games like today. I think we deserved it but the fair thing would have been for City to win it because they had the dominance and the chances.
“I value a lot the English refereeing and with the added factor of VAR all the decisions are justified.”
More goals outside the box than anyone else – the stats
Manchester City suffered their first home defeat against a promoted side in 42 Premier League games, since losing 2-0 against Reading in February 2007.
Leeds have become just the fourth promoted side to win away against the Premier League leaders in the competition’s history, after Ipswich at Norwich in December 1992, Derby at Manchester United in April 1997 and Hull City at Arsenal in September 2008.
Stuart Dallas became the first player to score a 90th-minute winner for Leeds in a Premier League game since Ian Harte vs Derby County in December 1999.
Leeds have scored more goals from outside the box than any other Premier League side this season (12).
Liam Cooper became the first Leeds player to be sent off in a Premier League match since Mark Viduka against Bolton in May 2004.
Manchester City are next in action in the second leg of their Champions League quarter-final against Borussia Dortmund on Wednesday, 14 April (20:00 BST). Leeds host Liverpool at Elland Road in the Premier League on Monday, 19 April (20:00).