Sinclair Broadcast Group Inc. has reached deals to sell nearly two dozen television stations as it works to get regulators to sign off on its purchase of Tribune Media Co.

Sinclair said Tuesday that the move to sell the 23 stations in 18 markets, some of which are owned by Sinclair and some by Tribune, was needed to obtain government approval for the $3.9 billion purchase of fellow television-station owner Tribune.

Sinclair...