The former NBA star led the city’s successful effort to keep the Kings from moving to Seattle and was recently sworn in as leader of the U.S. Conference of Mayors.

But he scored what might have been his biggest victory when he represented NBA players in demanding one of the harshest penalties in the history of U.S. sports against Donald Sterling, the owner of the Los Angeles Clippers, over racist remarks.

After intense lobbying by Johnson and numerous others, NBA Commissioner Adam Silver banned Sterling from the league for life, fined him $2.5 million, and said he would urge the NBA’s board of governors to make Sterling sell the Clippers.

“I hope that every bigot in this country sees what happened to Mr. Sterling and recognizes that if he can fall, so can you,” said Johnson, 48, who became Sacramento’s first African-American mayor in 2008, the same year the nation sent its first black president to the White House.

In targeting Sterling, Johnson used his unique experience as a former player and elected official to drive the discussions with NBA executives on behalf of the National Basketball Players Association.

NBA players were willing to take the unprecedented step of boycotting playoff games if the commissioner didn’t include the mandate for Sterling to sell the Clippers.

“For politicians, these moments happen and you either show you have it or you don’t,” said Chris Lehane, a Democratic strategist who has worked with Johnson throughout the fight to keep the Kings in Sacramento. “It was a slam dunk when it came to demonstrating he has what it takes.”

Johnson, a playmaking point guard and scorer who played for the Cleveland Cavaliers and Phoenix Suns from 1988 to 1999, called the Sterling scandal a defining moment for the NBA and said he was personally offended by the remarks.

“We may not have the power to force Mr. Sterling to sell his team, but make no mistake, we believe that Mr. Sterling should no longer have the privilege of being an owner of an NBA team,” Johnson wrote in a Facebook post before Silver handed down his punishment.

Clippers coach Doc Rivers said he didn’t know the mayor could speak so eloquently.

“My goodness,” Rivers said. “Just the rallying cry that this is not just about the Clippers or the Lakers or L.A. This is something bigger. It was great.”

Johnson’s political trajectory has been rising since he returned to his hometown of Sacramento.

During his first mayoral campaign in 2008, he fought allegations of misusing federal grants while running a charter school. Despite the claims, he ousted the incumbent with a pledge to raise the profile of the city. He compared himself to then-candidate Barack Obama and also campaigned on the promise of change.

His personal profile has also been on the rise. In 2011, he wed former Washington, D.C., schools chancellor Michelle Rhee in a private ceremony in Tennessee after plans for a much larger wedding drew intense public scrutiny. Rhee was featured in the school reform documentary “Waiting for Superman” and founded the advocacy group StudentsFirst.

The couple attended Obama’s first inauguration and they were among 350 guests at a White House state dinner honoring French President Francois Hollande in February.

While the Clippers made recent headlines, it’s been the Kings that have dominated much of Johnson’s time.

Sacramento had a topsy-turvy relationship with former Kings owners George, Joe and Gavin Maloof as the franchise struggled and proposals for a new arena came in fits and starts. The Maloofs considered moving the Kings to Las Vegas, Anaheim and Virginia Beach until announcing an agreement that called for investor Chris Hansen to buy the team and move it to Seattle.

Johnson, however, made it tough for the team to go by getting the City Council to approve a plan for a $447 million downtown arena with a $258 million public subsidy.

In the end, the Maloofs sold the Kings and the new Sleep Train Arena to a group led by TIBCO Software chairman Vivek Ranadive — and the team stayed put.

Ranadive and Tim Leiweke, president and CEO of Maple Leafs Sports & Entertainment, described Johnson as passionate, hardworking and charismatic.

“He’s the kind of guy that you would love to have sitting next to you on a long flight,” Ranadive said.

Earlier this year, Johnson was recruited by the players union to help find a new executive director. Now, he is hearing his name mentioned as a possible candidate for the position.