LeBron James has endorsed Hillary Clinton for president.

The Akron, Ohio-based NBA star exclusively announced his decision in an op-ed published on Business Insider Sunday evening. His op-ed will also run in the local paper, the Akron Beacon Journal, which has endorsed Clinton for president.

In the op-ed, James wrote that his endorsement decision came down to a few factors.

James has spent significant time and money building up his hometown of Akron, mentoring local students and, in some cases, paying for their college tuition through the LeBron James Family Foundation. He said he feels Clinton is the only candidate who "understands the struggles of an Akron child born into poverty."

Clinton, James said, is also the best candidate to carry out President Barack Obama's legacy.

James is close with the president and helped him campaign in 2008. A source close to James said he and Obama know each other socially and occasionally text about basketball. Obama sent James a congratulatory text after his team, the Cleveland Cavaliers, overcame a 3-1 deficit in the NBA finals and beat the Golden State Warriors in game 7.

LeBron James says he decided to endorse Hillary Clinton over Donald Trump for president in part because he feels she will carry on Barack Obama's legacy. James calls Obama a "good friend." White House via Flickr Additionally, James said the US needs a president who will bring the country closer.

"I do know we need a President who brings us together and keeps us unified," he wrote in the op-ed. "Policies and ideas that divide us more are not the solution. We must all stand together – no matter where we are from or the color of our skin. And Hillary is running on the message of hope and unity that we need."

James' endorsement could aid Clinton in one of the election's critical swing states, Ohio, where she and Donald Trump are currently battling for votes. Recent polls have shown Trump with a slight lead in the bellweather state.

It's somewhat unusual for an athlete like James, who has hundreds of millions of sponsorship dollars on the line, to take a stand. But increasingly, athletes are making their opinions known on hot-button issues.

NFL player Colin Kaepernick, for example, has been kneeling during the national anthem to protest perceived racial injustice. James, along with fellow NBA stars Chris Paul, Carmelo Anthony, and Dwyane Wade, opened ESPN's ESPY awards this year with a discussion about gun violence.

In an August interview, Business Insider asked James why he isn't afraid to speak out. James said, "If it feels right to me, then I believe it should be spoke upon."

You can read James' full op-ed and endorsement of Hillary Clinton here.