Kentucky has agreed to a contract extension with head coach John Calipari that will see him finish his career with the Wildcats, a school official told ESPN.

Calipari confirmed the news on his radio show. "Where else would I want to coach?" he said.

Calipari had been in contact with UCLA about the school's open head-coaching position and had been offered $48 million over six years, The Athletic reported.

"It has nothing to do with the other stuff ... people call every year," he said. "They presented it to me, and I appreciate it."

Calipari, whose current contract at Kentucky runs through 2024, is the highest-paid basketball coach in the country, with total compensation of $9.2 million this year, according to the USA Today Sports database. He receives a reported retention bonus of $2.6 million in each of the next three Julys.

UCLA has cast a wide net in its search for a replacement for Steve Alford, who was fired Dec. 31. The Bruins have gauged the interest of a number of big-time coaches, sources told ESPN, including Calipari and Virginia's Tony Bennett.

Sources said the Kentucky deal is constructed as a contract extension until Calipari retires and then as a lifetime role as ambassador to the university.

"It's not an endless contract," Calipari said on ESPN's Get Up! on Wednesday morning when asked about critics of the deal. "When it comes out, I think everyone will see that that it's pretty logical what they presented to me, something that I was comfortable doing."

Kentucky went 30-7 this season, earning a 2-seed in the NCAA tournament and advancing to the Elite Eight before losing to Auburn 77-71 on Sunday.

Calipari has been to four Final Fours with Kentucky, in 2011, 2012, 2014 and 2015, winning the national championship in 2012. The loss to Auburn marked the third season in a row that the Wildcats advanced to the second weekend of the NCAA tournament but fell short of the Final Four.

Calipari, 60, has a 305-71 record at Kentucky and an official lifetime record of 708-209. He has led his teams to the NCAA tournament 20 times in 27 seasons, with four official Final Fours and one title.

Calipari has twice taken teams to the Final Four only to have the wins vacated by the NCAA. His 2007-08 Memphis team, which lost to Kansas in the title game, was forced to vacate all 38 wins from the season, including five NCAA tournament wins, because star player Derrick Rose's SAT scores were invalidated. Calipari's UMass team's Final Four appearance in 1996 was erased after it was determined that star player Marcus Camby had accepted money from two sports agents.