James led the scoring for Cleveland after the Cavaliers had trailed for much of the contest as the Mavericks raced into an early 23-7 lead.
The pivotal moment in a 110-107 win for the Cavaliers – their eighth consecutive victory – came with 13 seconds to go in overtime, when Kyrie Irving nailed a long-range three-pointer to seal the win.
It capped a remarkable transformation in fortunes for the Cavaliers, who struggled to find the basket all night, with Irving and Kevin Love both missing a succession of attempts.
Cleveland’s winning streak might have come to an end had Dallas veteran Dirk Nowitzki not squandered a gilt-edged opportunity in the closing seconds of regulation.
Nowitzki looked certain to score after finding himself isolated with Cleveland guard Iman Shumpert. But Shumpert managed to strip Nowitzki and the chance was gone.
A nerve-jangling final quarter saw the lead change 10 times, while the game was tied three times in the final two minutes.
Cleveland now lead the Eastern Conference standings with a record of 27-9, ahead of the Toronto Raptors (24-15).
DURANT LATE SHOW
In Minneapolis, Kevin Durant underscored his importance to the Oklahoma City Thunder once again with a 30-point haul which helped see off the Minnesota Timberwolves.
Durant reeled off 12 points in the final three minutes to steer the Thunder safely to a 101-96 victory which left them with the third best record (27-12) in the Western Conference behind Golden State and the San Antonio Spurs.
However, Durant was unhappy that he left it late to deliver the goods.
“I’ve got to get it going there in the first three quarters,” Durant said.
“Can’t just come out and try to save the game and make shots in the fourth. I’ve got to get it going early.”
Russell Westbrook added 22 points for Oklahoma City, narrowly missing out on a triple double with 11 assists and seven rebounds.
San Antonio meanwhile extended their winning streak to nine games after a scintillating 31-point performance from Tony Parker helped the Spurs to a 109-99 victory over the Detroit Pistons.
LaMarcus Aldridge weighed in with 22 points and 13 rebounds while shooting guard Manu Ginobili finished with 15 points and five rebounds as the Spurs improved to 34-6.
Veteran centre Tim Duncan added 14 points and nine rebounds with Boris Diaw supplying 12 points.
French star Parker, 33, described his performance as a blast from the past.
“Just young Tony, I guess,” Parker said modestly.
“It’s very rare, just one of those nights,” said Parker, who had his highest-scoring game since finishing with 32 points against Chicago last season.
Spurs coach Gregg Popovich revealed he had placed the onus of the scoring on Parker during the game.
“At the start of the third quarter, I told him, ‘We’re going to need you to score. You’ve got all kinds of opportunities.'”