The world’s greatest basketball player and one of the sport’s premier franchises are joining forces. After a five-year playoff drought, the Lakers are back, planning to make a run at the two-time defending champion Warriors and add to their already illustrious history.

And they now have LeBron James — the one player who has toppled the Bay Area dynasty — on their side.

James’ agency, Klutch Sports, announced the NBA-shattering news early Sunday night in a press release, that James was leaving his hometown Cavaliers for the second time and will sign a four-year deal worth $154 million, the maximum allowed. He does have an opt-out after the third year, ESPN reported, and will make $35.65 million his first year, $37.43 million his second, $39.21 million his third and $41 million his fourth — provided he doesn’t opt out.

James left money on the table to go to Los Angeles — Cleveland could have offered him $207 million over five years — and the better team in the on-the-rise 76ers. Lakers president of basketball operations Magic Johnson was at one of James’s homes in Los Angeles on Saturday night and met with him for several hours, ESPN reported, rather than being at the team facility for scheduled free-agent calls.

James posted to his Instagram story: “Thank you Northeast Ohio for an incredible 4 seasons. This will always be home.”

It included a photo of the 2016 championship parade — Cleveland’s first title in 52 years — when the Cavaliers topped the Warriors in seven games. On Friday, he declined his $35.6 million 2018-19 player option to remain with the Cavaliers after they were swept in the Finals by the Warriors.

James left his hometown team once before, when he famously took his talents to South Beach in 2010 after playing the first seven seasons of his career in Cleveland. He returned home after four years — and two titles in Miami — and brought a title to Cleveland as he had vowed.

James has clashed with Cavs owner Dan Gilbert in the past. When he left the first time, Gilbert said the move was a “cowardly betrayal” and promised the Cavaliers would win a title before James. This time, the Cleveland boss took the high road in a lengthy statement, thanking James for the title he brought home, wishing him and his entire family well and promising to retire his No. 23 jersey one day.

“LeBron, you came home and delivered the ultimate goal,” Gilbert wrote. “Nothing but appreciation and gratitude for everything you put into every moment you spent in a Cavaliers uniform.”

Lakers legend Kobe Bryant, who won five championships, tweeted: “Welcome to the family @KingJames #lakers4life #striveforgreatness @JeanieBuss @MagicJohnson and RP well done!!!”

Now it will be interesting to see if the Lakers can swing a deal with the Spurs for on-the-block star wing Kawhi Leonard after missing out on Paul George. ESPN reported shortly after the news Leonard, the two-time defensive player of the year, wants to be a Laker, though those trade talks have not progressed, according to multiple outlets. The Lakers also have expressed interest in star big man DeMarcus Cousins, who is coming off an Achilles tendon tear in January. James once called the 27-year-old Cousins “the best big man in our game.”

Following the blockbuster news, ESPN reported the Lakers had agreed on a one-year, $12 million deal with guard Kentavious Caldwell-Pope, also landed Brooklyn wing Lance Stephenson, a heated adversary of James’, on a one-year deal worth $4.5 million, and added former Warriors center Javale McGee on a one-year contract for the league minimum.

Those moves, however, fueled speculation the Lakers have hurt their odds of adding another star to complement James. But they can free up $11.6 million in cap room by renouncing their rights to restricted free agent Julius Randle. Los Angeles can also use the stretch provision on Luol Deng, who is owed $36.8 million over the final two years of his deal. That would create $9.8 million in cap space. In other words, the Lakers will have to make moves to be able to further improve their team barring a creative trade.

But James’ presence alone has already significantly elevated the Lakers in the eyes of experts. The William Hill Sports Book installed them as 7-2 to win it all next season, behind only the Warriors at 11-10.

In an ironic twist, the Lakers were in position to add two max contracts this summer after dealing Jordan Clarkson and Larry Nance Jr. to the Cavaliers for Isaiah Thomas, Channing Frye and the Cavs’ 2018 first-round pick, which became Michigan forward Moritz Wagner. Thomas and Frye were in the final year of their respective contracts while Clarkson and Nance didn’t make much of an impact for Cleveland in its run to the Finals.

“Wouldn’t have made the move if I wasn’t confident,” Johnson said at the time.

Speculation was rampant that George opting to remain in Oklahoma City at the start of free agency at midnight Sunday might have soured James on the Lakers. Not only did the five-time All-Star from nearby Palmdale, Calif., stay with the Thunder on a four-year, $137 million deal, he didn’t even grant Los Angeles a meeting. However, the Lakers got the big prize in the 33-year-old James, who has led his team to the NBA Finals the past eight years and is a four-time league MVP.

ESPN reported James’ agent, Rich Paul, was meeting with the 76ers brain trust of owners Josh Harris and David Blitzer along with coach/acting general manager Brett Brown on Sunday, though James was not expected to be present for the powwow. Philadelphia seemed to make the most sense, since it could offer the same deal James accepted with the Lakers, and had two burgeoning young superstars in Joel Embiid and Ben Simmons to pair with the King.

However, the allure of Los Angeles and the glitz of the Lakers won out. They do have some impressive young players, such as Kyle Kuzma, Brandon Ingram, Lonzo Ball and Josh Hart. While the Spurs are reportedly not interested in Ball, the other three could be a part of a deal for Leonard.

Coming of a 35-win season, the Lakers obviously still have a lot work to do in reshaping their roster to compete with the Warriors and Rockets. But this first step was a massive one, and they followed it up with a few minor moves.

The King can now call Staples Center his kingdom and the Lakers can dream big once again. Hollywood just got one of sports’ biggest stars.