Facing his first serious threat to re-election, Maryland Rep. Andy Harris, a close friend and ally of embattled Iowa Rep. Steve King, is attempting to transform himself into the very type of moderate he beat a decade ago on his march to power.

Harris, a Republican who represents Maryland’s Eastern Shore and parts of the Baltimore suburbs, rose to prominence while taking positions so extreme that he managed to make headlines as a state legislator. In the decades since, Harris and King have become partners in the right-wing Freedom Caucus and have mutual adoration for eastern European fascists. Now, as King faces a backlash for his white supremacist ties, Harris has receded into the background, sticking as close as possible to Maryland’s moderate Republican governor, Larry Hogan, for cover.

But with the election fast approaching, local Democrats are drawing attention to Harris’s ties to King. “While Marylanders remain appalled by the hate-filled attacks against Jewish Americans in Pittsburgh last week, Congressman Harris owes it to his constituents to condemn Steve King,” Baltimore County Democratic Central Committee chair Tara Ebersole said in a recent statement.

On Tuesday, Harris is facing Democrat Jesse Colvin, an Army Ranger whose campaign ad, which features Colvin and his Republican wife, a former police officer, at a shooting range, picked up significant media attention in the region.

Having run for Congress as an opponent of the Affordable Care Act, Harris is now a strong defender of making sure that insurance companies don’t discriminate against people with pre-existing conditions. Though his voting record suggests otherwise, Harris said at a debate with Colvin in Easton, Maryland, that he will stand up to President Donald Trump when need be.

Harris’s rhetorical slide to the center in the closing months of his current campaign reflects a nationwide move by House Republicans, who spent every election cycle since 2010 vowing to repeal Obamacare but are now feeling heat from constituents.

Yet Harris, who has served in Congress since 2010, first ran for the state Senate in 1998 in a primary against the GOP’s minority leader, challenging him as too moderate for his lack of a full commitment to a late-term abortion bill.

One of his first high-profile battles was with the University of Maryland over a student group’s plan to screen an explicit film on campus. Harris, then a state senator, called it “poison” and made national headlines by threatening to withhold hundreds of millions of dollars from the university if anybody pressed play.

In 2008, Harris made his first run for federal office. He again primaried a Republican, this time taking on moderate GOP Rep. Wayne Gilchrest, challenging the Vietnam War veteran for being insufficiently supportive of the war in Iraq. Harris ran so far to the right during his primary that Gilchrest endorsed the Democrat, and Harris lost in the general election to Frank Kratovil.

The climate was much more favorable for Republicans in 2010, as the tea party wave swept them into power. Harris beat Kratovil easily in a rematch, and hasn’t had a significant challenge since. A physician, Harris centered his 2010 campaign on opposition to the Affordable Care Act, equating a public health insurance option with a government takeover of health care. Kratovil opposed the public option, but Harris still made the issue the centerpiece of his campaign.

UNITED STATES - OCTOBER 17: From right, Andy Harris, Republican candidate for Congress from the 1st district of Maryland, participates in the candidate forum with Rep. Frank Kratovil, D-Md., and two independent candidates at Centreville High School in Centreville, Md., on Sunday, Oct. 17, 2010. (Photo By Bill Clark/Roll Call via Getty Images) (CQ Roll Call via AP Images)

Andy Harris, right, participates in a candidate forum with Rep. Frank Kratovil, D-Md., at Centreville High School in Centreville, Md., on Oct. 17, 2010.

Photo: Bill Clark/Roll Call via AP

Harris won handily, but then quickly made a fool of himself post-election. Upon arriving in Washington, Harris was told that he wasn’t eligible for his publicly funded health insurance until he was sworn in. That wouldn’t work, Harris said in front of his colleagues during an orientation — he needed it now. Wasn’t there some type of public option he could buy into?

Harris joined the archconservative Freedom Caucus once in office, and was regularly among the loudest holdouts in support of a government shutdown. He made culture war headlines again by picking a fight with the District of Columbia over its attempts to liberalize its marijuana laws. He also joined King in his alliance with far-right European demagogues. In January 2018, Harris, King, and three other Republicans planned to visit the Czech Republic’s Freedom and Direct Democracy Party, just a few weeks after the party’s secretary declared, “Jews, gays, and Roma should be gassed.” Human Rights Watch dubbed the planned trip a “trans-Atlantic hatemonger hoedown,” and the visit was canceled amid backlash.

“I didn’t make the agenda,” Harris later said, when questioned by local press about the trip. “I mean, you could call it fake news. It never happened,” he said, adding that if the trip had gone forward, he would have skipped that particular meeting.

But Harris has also come to the defense of Hungarian Prime Minister Viktor Orbán, who has said that “ethnic homogeneity” is key to the country’s development. When a group of U.S. senators wrote to the State Department warning of Orbán’s erosion of the rule of law, Harris shot back with a letter demanding that the senators butt out. (Harris’s father fought in the pro-Hitler Hungarian army, and Harris often refers to him as an anti-communist fighter. The fascist alliance did indeed go to war against the Soviet Union, which captured and imprisoned Harris’s father.)

Moderation has been tricky for Harris, though. When Christine Blasey Ford stepped forward to accuse  Brett Kavanaugh, then a Supreme Court nominee, of attempted rape, Harris suggested that the “troubled woman” must have “psychological problems.”