You can almost always withdraw before the wagering is cleared. The cost is the bonus: requesting a payout with an active bonus forfeits it, along with everything won from bonus funds.
Your deposit and your cash-balance winnings are unaffected. They were never locked.

The calculation that decides it
Clearing a requirement costs roughly 4% of the turnover still owed, because that is the house edge on a typical slot.
| Turnover still owed | Expected cost to finish | Worth it for a $50 bonus? |
|---|---|---|
| $300 | $12 | Yes |
| $800 | $32 | Marginal |
| $1,250 | $50 | Break-even |
| $2,000 | $80 | No |
Set that expected cost against the bonus you would keep. If finishing costs more than the bonus is worth, the bonus stopped being an asset some time ago and is now just a reason to keep playing.
The second half of the test is the cash in front of you. Holding $240 of withdrawable balance against a $50 bonus and $1,600 of turnover remaining is not a close decision.
Three situations where forfeiting is clearly right
You are ahead and the requirement has barely moved. The balance that makes the grind survivable is the same balance you would be risking to get there.
The expiry is close. A requirement that cannot realistically be finished in the time left is worth nothing. Playing faster to beat a clock is how bet sizes creep up and maximum bet caps get breached.
The cap is already binding. If the payout ceiling is $100 and your bonus balance is $340, finishing converts $100. Three quarters of what you are grinding for is not going to arrive.
Two where it is worth staying
The requirement is nearly done. With $150 left on a $60 bonus, finishing costs about $6 in expected terms. That is a good trade.
Cash is spent first and you have not touched the bonus. In that structure your deposit went first, so the bonus is untouched and the requirement has not started. There is nothing to weigh up yet.
Which pot pays for each spin is set by the terms, and it is explained in bonus balance vs real balance.
Doing it cleanly
Look for a cancel or forfeit option in the promotions area first. Using it explicitly is tidier than a withdrawal request that triggers the same result through a manual review.
Expect the payout to be slower than usual either way, because a bonus review runs alongside verification. Documents submitted at signup rather than at cashout remove most of that delay.
The version where this never comes up
None of this applies to a bonus with no wagering attached. Winnings sit in the cash balance from the first spin, and a withdrawal request is just a withdrawal request.
The same is true of the non-sticky structure up to the point your own cash runs out, because until then no requirement has started.