Nowitzki scored 29 points, driving for the go-ahead dunk with 2:45 remaining, and the Mavericks beat the Heat 112-103 on Thursday night to take a 3-2 lead in the NBA Finals.
Five years after going up 2-0 on the Heat, the Mavs finally got that elusive third victory, and can wrap up their first championship in Game 6 at Miami on Sunday night.
"We're a very resilient team, you know that," guard Jason Terry said. "We've been in tough battles all playoffs long. It's not going to stop. It's going to get even harder. But we're ready. We're determined, and this is our time."
James, who called this game "now or never," responded from his worst playoff performance with 17 points, 10 rebounds and 10 assists, and Dwyane Wade battled through a sore left hip after a first-quarter collision to finish with 23 points.
Chris Bosh had 19 points and 10 rebounds for the Heat, who get the final two games at home with history against them as they try to win a title in their first season together: In the 26 previous finals that were tied 2-2, the Game 5 winner won 19 of them.
"We fought hard all season for home-court advantage. We're down 3-2," Bosh said. "We protect home court, we win the series, so we just have to keep that in mind."
The Mavs shot 60 percent through three quarters, briefly gave up the lead in the fourth, then controlled the final few minutes, just as they had in thrilling comebacks in Games 2 and 4.
This time, they got to play from ahead thanks to some sizzling shooting: 56.5 percent from the field, including 13 of 19 (68 percent) from 3-point range.
"We made more shots," Dallas coach Rick Carlisle said. "We did a lot of good things defensively, which led to good offense. ... You never know when the games are going to go that way. The thing we've got to do is we've got to make sure our defense is consistent."
Terry scored 21 points and J.J. Barea had 17 for the Mavs, who insisted at some point their shots would start falling even against the Heat's stingy defense. Jason Kidd and Tyson Chandler both finished with 13 points.
"I felt great. I felt great. I was in rhythm tonight," Terry said. "I came out aggressive, something we have to continue to do. We're not happy with our defensive performance, but offensively, if we score 100, I told you what would happen."
Their offense was simply too good, despite a good bounceback for James.
James scored eight points, going just 3 of 11 in Game 4, the first time in 90 postseason games he didn't hit double figures. It's been a rough first finals in Miami for James, who has been accused of everything from "shrinking" to "checking out" in the fourth quarters, when he had just nine points through the first four games.
Trying to pump himself up, James wrote "Now or Never!!" on his Twitter page early Thursday morning, later calling this the biggest game of his career.
But they feel the same urgency in Dallas, where the slogan "The Time is Now" is printed on those blue T-shirts that surround the court, and where the Mavs are loaded with 30-somethings -- late 30s, in Kidd's case -- who could be on their last shot at an NBA title.
Nowitzki said early Thursday he felt "great," having shaken the fever that rose to 101 degrees Monday night. This time, the health concern was Wade, who banged his hip in the first quarter and appeared to be limping at various points from there.
"I don't talk about injuries," Wade said. "It was unfortunate I had to leave the game, but I came back and finished it."
He remained in the locker room to start the second half, coming back onto the court about the midway point of the period. By then, the Mavs seemed in too good a groove to be cooled off no matter who Miami had out there.
A disgusted Heat coach Erik Spoelstra was already walking onto the court to call time out by the time Chandler went up to dunk after catching the ball all alone under the basket, giving Dallas a nine-point lead that matched its largest of the series. Miami trimmed it to 84-79 after three quarters, then stormed into the lead midway through the fourth with a 9-0 run, all layups, dunks and free throws until Wade's 3-pointer made it 99-95 with 4:38 to play.
The Mavs tied it at 100 on Terry's 3-pointer with 3:23 left, and after James missed, Nowitzki drove for a baseline dunk and a 102-100 lead with 2:45 to go. James was called for an offensive foul and missed a 3-pointer on Miami's next two possessions before Kidd drilled a 3-pointer to make it 105-100, sending the crowd into a delirious chant of "Beat the Heat! Beat the Heat!"
The teams were at the same point as their 2006 matchup after four games, but that one was already in the midst of a massive swing by then. Miami won the final four games behind Wade, the MVP of that series who had been Miami's best player in this one, averaging 29.8 points.
This one has been the developing into one of the closest finals the NBA has ever seen. There hadn't been three straight games decided by three points or fewer in the championship round since 1948, according to STATS, LLC, when the Baltimore Bullets and Philadelphia Warriors played Games 2-4 within a three-point margin during the Basketball Association of America finals, a year before that league merged with the National Basketball League to become the NBA.
The first four games were determined by 15 total points, the fewest since a 12-game difference between the Celtics and Lakers in the 1969 Finals.
And all eyes were on James, just as they have been since he bolted Cleveland for a better shot at a championship in Miami.
He vowed to be more aggressive after his puzzling Game 4. He caught the ball in the post more frequently, but his jumper was still off for much of the game.
James threw up an airball with his left hand on his first shot, and when he did finally score, the Mavs quickly came back with six straight points for an early 13-6 lead, a promising start for a team that had been playing from behind nearly all series.
Wade walked gingerly to the locker room with a left hip contusion with about 3 minutes left in the period after colliding with Mavs reserve Brian Cardinal on a drive to the basket, and didn't return to the bench until more than 3 minutes into the second. But the Heat hung in while he was gone, even taking a 31-30 lead when the Mavs turned it over on their final possession and Mario Chalmers threw in a heave from just inside midcourt to beat the buzzer, nearly a duplicate of the finish of the first quarter in Game 3 that stunned Dallas.
James had a basket inside that gave Miami a six-point lead with 4:26 left in the half, but Dallas closed with a 14-5 push, taking a 60-57 edge to the locker room after Nowitzki's jumper with 6.1 seconds remaining. The Mavs shot 12 of 17 in the quarter, and after not reaching 30 points in any period through four games, hit that number in each of the first two quarters of Game 5.
The Mavs again played without backup center Brendan Haywood because of a hip injury.