Paul Arriola, a D.C. United star and member of the U.S. men’s national team, apologized Saturday for tweets he posted in 2012 when he was 17, saying he was “ashamed” for his use of “offensive and discriminatory words.”

In a statement posted to his Twitter account, Arriola said, “I can assure you that I have grown and learned since then and those tweets did not accurately portray me as a human being at that time in my life, and they certainly do not now.”

Since Feb. 1, Arriola has been on loan to Swansea City, a Welsh club that competes in the second-tier English Championship. He is scheduled to rejoin United in May.

The four since-deleted tweets from 2012 were purportedly discovered Thursday by a fan of Cardiff City, Swansea City’s rival.

In one, replying to a friend, Arriola used the n-word and referred to someone who he said was “darker than an indian.” In another, he repeated a lyric from a song by Rick Ross and Drake that includes the n-word.

One included hashtags apparently directed toward a high school friend and said, “I didn’t know black people liked swimming?” And in another, Arriola wrote, “Women commentators, that’s a no no.”

Reached in Swansea on Saturday night, Arriola, now 26, said he did not want to comment and referred to his statement.

In a statement, United said it does not condone “any form of offensive or discriminatory language or behavior from anyone associated with our club.”

The organization also said it supports “Paul’s decision to be the one to address these historical tweets and his apology.” United said it will provide bias training for all members of the organization, and Arriola will participate upon his return from Europe.

“Those who know me know my true character through my heart, desires and actions,” Arriola said in his statement.

Swansea City said it “has been discussing the issue with Paul, and we support his decision to be the one to address these historical tweets and to issue an apology.”

The U.S. Soccer Federation, which oversees the national teams, said in a statement: “We have seen the offensive tweets and are encouraged he has apologized and taken responsibility. It is important Paul recognized and acknowledged that those expressions, though made long ago, are not acceptable.”

Arriola, a native of Chula Vista, Calif., joined United in August 2017 from Mexican club Tijuana and quickly became a fan favorite. He has been among the club’s most important players, filling a variety of roles and earning regular call-ups to the national team, which this fall will begin the 2022 World Cup qualifying campaign.

More soccer from The Post: