How to withdraw stake pool deposit refund with cardano-cli

I was trying to find some topics on transferring the 500 stake pool deposit refund to my personal wallet. Found How do I Retire Pool and/or Transfer ADA from Pool Wallet to Daedalus Wallet but that is using CNTOOLs, which I don’t have. Found Retiring a Stake Pool - Stake pool course, but it doesn’t talk about withdrawing the refund. Any websites out there that show how to get the refund withdrawn to a wallet?

edit: I’ll see if this works Withdraw rewards - Stake pool course

Had to do some tweaks to run on mainnet versus testnet. Going to need another pair of eyes because I’m doing something wrong…getting the dreaded ValueNotConservedUTxO error

balance in the payment address: 23232766
drafting the transaction:
cardano-cli transaction build-raw
–tx-in **#0
–tx-out addr1
–withdrawal stake1
–ttl 0
–fee 0
–out-file withdraw_rewards.raw

calculate the fee
cardano-cli transaction calculate-min-fee
–tx-body-file withdraw_rewards.raw
–tx-in-count 1
–tx-out-count 1
–witness-count 2
–protocol-params-file protocol.json

result: 177557 Lovelace
out value: expr 23232766 - 177557 = 23055209

build transaction
cardano-cli transaction build-raw
–tx-in *#0
–tx-out addr1
–withdrawal stake1
–ttl 57319965
–fee 177557
–out-file withdraw_rewards.raw

Anyone see anything that I’m doing wrong? The “withdraw rewards” website shows the transaction output including only the difference between the payment address balance minus the fee. I did try to include the 500 ada in an alternate attempt, but same error. Usually I can these out with several attempts, but not succeeding this time. Here’s the error

Command failed: transaction submit Error: Error while submitting tx: ShelleyTxValidationError ShelleyBasedEraAlonzo (ApplyTxError [UtxowFailure (WrappedShelleyEraFailure (UtxoFailure (ValueNotConservedUTxO (Value 523232766 (fromList [(PolicyID {policyID = ScriptHash “******”},fromList [(“BIGO”,1)])])) (Value 23232766 (fromList )))))])


If u already retired the pool, you probably received back 500 ADA as a reward (check the pool reward address on

First step is to withdraw the rewards (move from stake address to payment address)

after u send the funds to payment address then u cand send to another address using …

At the end probably (if is a cli wallet) u will need to deregister the stake address to receive back 2 ADA paid when u registered the stake address