WASHINGTON — From the moment he rolled into town with the Tea Party wave in 2011, Representative Trey Gowdy of South Carolina began to distinguish himself from the 86 other Republican freshmen in the House.

He had a confrontational style with Obama administration officials, a skill he had honed during his two decades as a prosecutor, not to mention an ever-changing hairstyle that varied from faux mohawk to Gordon Gekko slick. But his genial personality and self-deprecating wit led Democrats to admit that they liked him, if not his politics.

So when it came time a year and a half ago for Speaker John A. Boehner to pick a chairman to lead a committee that would investigate the politically sensitive 2012 attack in Benghazi, Libya, Mr. Gowdy, 51, was an obvious choice. Mr. Boehner believed Mr. Gowdy would be able to keep the more volatile members of his committee from making outlandish accusations about Hillary Rodham Clinton, the secretary of state at the time of the attack.

But now, as he prepares for the committee’s most high-profile moment, Mrs. Clinton’s public testimony on Thursday, Mr. Gowdy — who, just a few weeks ago, was being asked by his Republican colleagues to run for a House leadership position — is struggling to uphold his panel’s credibility and his own personal standing after a string of embarrassing blunders.