The Biden administration has approved the broadest expansion of federal background checks in decades in an attempt to regulate a fast-growing shadow market of weapons sold online that has contributed to gun violence.

Under a rule being released on Thursday, the Bureau of Alcohol, Tobacco, Firearms and Explosives will require anyone “engaged in the business” of selling guns at a profit, including at gun shows and through private sellers, to register as a federally licensed firearms dealer. That means those sellers must run background criminal and mental health checks on potential buyers.

The new regulation, which is likely to face legal challenges, could add as many as 23,000 federal dealers to the 80,000 already regulated by A.T.F., an underfunded division of the Justice Department that already struggles to monitor sellers.

The rule, which drew more than 380,000 public comments, will take effect in a month.

President Biden, repeatedly blocked from enacting universal background checks by Republicans in Congress, is leveraging a provision of the sweeping bipartisan gun control law passed in 2022 to achieve an elusive policy goal that enjoys widespread public support: closing the so-called gun show loophole.

Expanding the number of federal firearms licensees was one of several gun control measures included in an executive order Mr. Biden issued in March 2023 after several mass shootings.

Unlicensed private sellers in many states have been able to legally sell at gun shows, out of their houses and through online platforms without having to submit to the background check system created to prevent sales to children, criminals, domestic abusers, and people with mental illnesses or drug addictions.