PHILADELPHIA -- An early 18-point lead evaporated into a late five-point deficit.
But somehow, the defending NBA champion Cleveland Cavaliers found a way to defeat the reeling Philadelphia 76ers.
It was a prime example of the type of game that championship teams tend to win and losing franchises drop.
"We will clean it up," James said. "It's a great learning experience for us. It's always great to have these kinds of games. I know we have room for improvement."
It is Cleveland's best start since winning its first eight games in 1976-77.
"We'll live with that and we'll be better next time," Cavaliers coach Tyronn Lue said. "We stayed poised. We were tested tonight and we came back and won, so I'm pleased about that."
Along the way, James also passed NBA Hall of Famer Hakeem Olajuwon to move into 10th place on the league's scoring list. James' driving layup with 6:02 left in the first quarter pushed him past Olajuwon's total of 26,946 points.
"I am just blessed to have had a chance to play with so many great players in two great organizations that have allowed me to blossom," James said. "It's a blessing and an honor."
Cleveland won its seventh straight game over Philadelphia.
Joel Embiid had 22 points in slightly more than 25 minutes for the Sixers. Ersan Ilyasova scored 21 points, Jahlil Okafor added 14 and Gerald Henderson had 11. Sergio Rodriguez contributed 11 assists as the Sixers fell to 0-5.
In the end, it wasn't enough as the Sixers dropped their 42nd straight game in October or November, dating to an overtime victory over the Milwaukee Bucks on Nov. 22, 2013.
"They're obviously a good defensive team and I think it kind of comes with experience," Henderson said. "I don't know if we've been in that kind of situation too many times where we know how important the ball is, but at the end of the game you're not going to get any more possessions to make it up. You have to make the most out of the ones you have at that moment. We didn't really do that."
The fourth quarter was electric with clutch baskets coming from both teams.
Philadelphia jumped ahead 96-91 with 6:10 remaining on a jumper by Henderson.
James followed with a vicious one-handed dunk and Embiid came right back with a short jumper. James then hit a 3-pointer to pull the Cavaliers within 98-96.
Smith's 3-pointer gave the Cavaliers a one-point lead and Ilyasova then knocked down a triple to put the Sixers back on top by two at 101-99.
After a timeout, James found Frye for a wide open 3-pointer and a 102-101 Cavaliers advantage with 1:05 to go.
Rodriguez then committed a costly turnover at midcourt, giving Cleveland another possession. Smith missed a 3-pointer and the Sixers called timeout with 7.3 seconds remaining.
Henderson attempted a drive to the basket but turned the ball over, Shumpert grabbed it and the final buzzer sounded with another Sixers loss.
"We tried to get Jo the ball," Sixers coach Brett Brown said of the last possession. "We had two turnovers there and that's stuff he will learn from. Sergio had the tough turnover that went off his leg at halfcourt. We had the tough play with Robert (Covington) on the charge, but I think the sad part is when you look at the complete body of work, especially after the first period, there's a lot of great stuff that came out of it with these guys."
Embiid scored seven points in the final 2:39 of the third quarter to pull the Sixers within 82-80. His fourth 3-pointer with four seconds remaining cut the advantage to two and ignited the raucous crowd with chants of "Trust The Process!"
James had a strong first quarter with six points, four rebounds and seven assists.
Philadelphia cut into the lead, getting within 47-44, but the Cavaliers responded with a 10-0 spurt to go back ahead 57-44. Cleveland led 57-46 at halftime with James (13 points) and Love (11 points) leading the way.
NOTES: Sixers coach Brett Brown said C Joel Embiid will continue to be limited to 24 minutes per game until Christmas and then will be re-evaluated. ... Cavaliers coach Tyronn Lue on F LeBron James averaging 10 assists per game: "It's all a feel for him. He has a great feel for the game." ... The Cavaliers are scheduled to visit the White House on Thursday in recognition of their championship last season. ... Sevyn Streeter will perform the national anthem at the 76ers' game on Dec. 16 against the Los Angeles Lakers. Streeter was supposed to sing the national anthem on Oct. 26 but wasn't allowed by Sixers to perform because she was wearing a "We Matter" jersey. ... The Sixers honored the 1966-67 championship team and the players donned throwback jerseys. ... Cavaliers G Kyrie Irving scored at least 20 points in each of the first five games.