LOS ANGELES (AP) — LeBron James has agreed to a two-year, $97.1 million contract extension through the 2024-25 season with the Los Angeles Lakers, his agent announced Wednesday.

Klutch Sports CEO Rich Paul said the league-maximum deal makes James the highest-paid player in NBA history. His new deal includes a player option that would keep the second-leading scorer in NBA history with the Lakers past his 40th birthday in December 2024.

The 37-year-old James is headed into the final year of his most recent contract with the Lakers, who signed the four-time NBA Most Valuable Player and four-time league champion in July 2018. The new deal means the 18-time All-Star will make $46.7 million this season.

Barring injury, James is likely to surpass Kareem Abdul-Jabbar as the NBA's career scoring king this winter. James and the Lakers also still hope to be in contention for another title if James and Anthony Davis can return at full health after an injury-plagued 2021-22 ended without a playoff appearance.

James’ new deal syncs with Davis’ most recent contract extension with the Lakers, allowing both to leave the Lakers or to negotiate new deals in 2024. Both superstars are represented by Klutch.

James' recommitment to the Lakers also silences persistent talk of his possible departure as a free agent or in a trade. James hasn't appeared to be going anywhere on social media or in his public appearances, and he praised the hiring of new Lakers coach Darvin Ham.

James has missed significant portions of the season due to injury in three of his four years with the Lakers. He was largely healthy in the elongated 2019-20 season when the Lakers won the franchise's 17th NBA title in the Florida bubble, and he has been every bit the dominant player of his prime when at full strength in the ensuing two years.

Although his contract status inspired plenty of offseason chatter, James seemed unlikely to relocate after spending the past four seasons of his 19-year career with the storied Lakers. His family is settled in Los Angeles, where his eldest son, Bronny, is a 17-year-old senior and college basketball prospect playing at Sierra Canyon High School in Chatsworth.

James has occasionally said he intends to play on the same team with Bronny when his son reaches the NBA. Although plenty of obstacles remain between the younger James and the NBA, he could be draft-eligible in the summer of 2024.