If you want to sweep a wallet, or simply consume an an entire UTXO for a Boltz swap, you'll need to know the final amount that will be sent by your wallet, meaning after deducting network fees, before creating the swap.
This is a bit tricky, as network fees depend on two things: the current miner fee level, usually expressed in "sat/vbyte" (mempool.space is a great place to query this) AND the destination address type (e.g. Segwit vs. Taproot).
Here is a step-by-step guide how to do it, using Sparrow Wallet as an example:
-
Open the "Send" screen in your wallet and select the wallet/UTXO to sweep. Paste any Taproot address as destination. Don’t have one at hand? Use this one (DO NOT SEND FUNDS!):
bc1p3c2kn0ulegyrxyaplkjjekehurerlegwupn0dwptwjegul5c0gzsxhffrk
. This is how it looks in Sparrow Wallet:We see the final amount that will be sent after deducting network fees is 711302 sats. Again: Do NOT send the transaction.
-
Open boltz.exchange, select the send and receive asset and paste
711302
in the upper box as amount you want to send.Paste the destination address, offer, or Lightning invoice for 709988 sats in our example and create the swap.
-
On the next page, ensure the amounts you are prompted to send matches 711302 sats:
-
Copy the address, replace the previous address in your wallet's send screen, once again make sure the send amount still states 711302 sats and if all checks out, send the transaction.
-
Done! 🎉