Trey Gowdy, the Republican congressman from South Carolina, retired from office last year, declaring his skills are better used “in a courtroom than in Congress.”

Now he’s coming back for impeachment.

A former prosecutor who led the House investigation into the 2012 attacks in Benghazi, Libya, Gowdy is poised to join President Donald Trump’s legal team, putting himself at the molten center of the confrontation between the White House and the Democratic House over Trump’s conduct in office. His task, and that of Trump’s other lawyers, is to defend the president and prevent GOP defections in the impeachment push, now centered on a call to Ukraine in which Trump discussed an investigation of rival Joe Biden and his family.

Gowdy, 55, is best known for his dogged, two-year investigation of Hillary Clinton that accused the Obama administration of lethal mistakes leading up the Benghazi attacks but produced no “smoking gun” pointing to wrongdoing by the former secretary of state.

Terry Sullivan, who ran Gowdy’s first congressional campaign in 2010, said the Trump team made the right call in hiring Gowdy, who has strong ties to congressional Republicans and key members of the administration and is skilled at making a case on television. Secretary of State Mike Pompeo and Rep. Jim Jordan, R-Ohio, one of Trump’s strongest defenders, served alongside Gowdy during the Benghazi panel. Democrats have subpoenaed Pompeo and are fighting for testimony from State Department officials as they investigate Trump’s dealings with Ukraine.

“It’s absolutely a super smart thing for the Trump (team) to do,” Sullivan said. “Trey is ridiculously smart — not only a darn good attorney but a very compelling and convincing individual.”

Trump called Gowdy “a terrific guy” Thursday but said he can’t start his legal work until January because of lobbying rules. Sekulow said congressional rules prohibit Gowdy from dealing with Congress for one year from his departure.

Now a lawyer in Greenville, South Carolina, Gowdy has been a regular contributor on Fox News since leaving Congress. On Wednesday, the news network announced it had cut ties with him.

Gowdy, who became chairman of the House Oversight Committee after the Benghazi panel finished its work in 2016, was largely hands-off in scrutinizing the Trump administration.

As a frequent GOP tormentor of Clinton, former Attorney General Eric Holder and other Obama-era officials, Gowdy was a stout defender of congressional oversight. In 2012, he declared, “The notion that you can withhold information and documents from Congress no matter whether you are the party in power or not in power is wrong. Respect for the rule of law must mean something, irrespective of the vicissitudes of political cycles.”

The White House this week declared it will not cooperate with the “illegitimate” impeachment probe and said no additional witnesses under administration purview would be permitted to testify to Congress or comply with document requests.

Rep. Mark Meadows, R-N.C., a Gowdy friend and Trump supporter, called Gowdy “a welcome addition” to Trump’s legal team.

“Trey is an accomplished prosecutor with the skills to bring a clear and articulate case to the American people,” Meadows said in an email.

Sekulow, Trump’s longtime lawyer, said he has known Gowdy for years and worked with him when Gowdy was in Congress.

“His legal skills and his advocacy will serve the president well. Trey’s command of the law is well known and his service on Capitol Hill will be a great asset as a member of our team,” Sekulow said in a statement.

Sen. Tim Scott, fellow South Carolina Republican and Gowdy’s best friend on the Hill, called Gowdy “one of the best legal minds in our country.”

Gowdy’s time as a prosecutor and member of Congress “will serve this nation as we seek the facts,” Scott said in a statement. “The president has added a well-respected person, and the American people will appreciate and benefit from his integrity and competence.”