Donald Trump wearing a suit and tie© Al Drago/Bloomberg NewsPresident Trump has expressed interest in pursuing the appointment of a special counsel to investigate allegations of fraud in the November elections and issues related to Hunter Biden, according to people familiar with the matter.

In recent days, the president has directed advisers to look for people who could serve in such a position, one of the people said, as lawsuits and other efforts by Mr. Trump and his campaign to reverse the election results flounder. White House officials and allies of the president on Capitol Hill and elsewhere have also pushed for the appointment of a special counsel, another person familiar with the discussions said.

White House chief of staff Mark Meadows has told people that the president is interested in pursuing a special counsel to investigate election fraud and wants to act quickly, one of the people said.

Senior White House officials have also discussed the possibility of pursuing a special counsel to investigate Hunter Biden, expressing frustration over Attorney General William Barr’s handling of investigations into Mr. Biden’s business and financial dealings and concern that the incoming administration of Joe Biden could seek to shut down any probes into Mr. Biden’s son, Hunter, an administration official said.

The White House declined to comment. A spokeswoman for Mr. Barr declined to comment. A spokesman for the Biden transition team declined to comment. Joe Biden isn’t implicated in the investigations into Hunter Biden, according to people familiar with the matter.

The president has expressed rising frustration with his attorney general in recent months, privately and publicly, according to aides, as efforts by the president and his supporters to overturn the election have repeatedly failed. On Friday, the Supreme Court rejected a suit by Texas’s attorney general to void 20 million votes in four key states. It’s the latest in dozens of losses in federal and state courts in suits alleging irregularities to override President-elect Joe Biden’s victory.

Mr. Barr’s announcement that the Justice Department hadn’t found evidence of widespread election fraud that would reverse Mr. Biden’s victory infuriated the president, the aides said, and Mr. Trump has openly accused the Justice Department of being involved in the election fraud he has alleged. A federal agency in charge of election security and organizations representing top election officials around the country have also deemed the election free from tampering.

Mr. Trump, in a meeting Friday, fumed about a Wall Street Journal report that Mr. Barr knew of an existing federal investigation into Hunter Biden before the election but worked to keep it from being publicly disclosed, a person familiar with the conversation said. In the meeting, Mr. Trump contemplated firing Mr. Barr, people familiar with the conversation said, adding that it is not clear whether Mr. Trump intends to follow through.

Aides and allies have for months urged the president not to fire Mr. Barr. For his part, the attorney general has told associates that he intends to stay on the job unless he is dismissed.

Under Justice Department regulations, the appointment of a special counsel would have to be made by the attorney general. A special counsel is appointed to pursue investigations with a level of independence not subject to day-to-day supervision by agency officials and is only removed by the attorney general for misconduct or a conflict of interest.

Associates of Mr. Barr said he is unlikely to name anyone to such a post, particularly after he appointed another prosecutor in October as special counsel to continue his examination of the origins of the Federal Bureau of Investigation’s 2016 Russia investigation. He disclosed that appointment earlier this month, saying he had kept it quiet for more than a month to avoid influencing the November election.

Mr. Trump and some Republican lawmakers have for months urged the Justice Department to investigate Hunter Biden and his business dealings, calls that intensified as the November election neared. Mr. Barr and other Justice Department officials resisted requests for information from several Republican lawmakers before the election about whether the department was investigating Mr. Biden, another person said.

Hunter Biden disclosed earlier this week that he had learned of a federal investigation into his tax affairs. He said he has acted legally and appropriately.

On Friday, Mr. Biden responded to questions shouted by reporters, saying: “I’m proud of my son.”

Adding to pressure on Mr. Barr, more than two dozen Republican lawmakers earlier this week signed a letter to Mr. Trump, calling on him to direct the attorney general to appoint a special counsel to investigate “irregularities in the 2020 election.” The effort was led by Rep. Lance Gooden (R., Texas), who said a special counsel is the “best option to bring to light to whatever happened in the 2020 election.”

Mr. Gooden hasn’t discussed his proposal directly with Mr. Trump, a spokesman for the congressman said. The Justice Department didn’t respond to the letter, a person familiar with the matter said.

The president on Thursday retweeted several tweets about the letter, calling the effort “great.”

The Hunter Biden investigation is being handled by the U.S. attorney’s office in Delaware, which is led by David Weiss. Mr. Weiss was a prosecutor for years in that office and a supervisor there for much of the Obama administration. His nomination by Mr. Trump to the top job in 2017 was supported by his home state’s Democratic senators, according to local media reports at the time.