Tx Doctor / Solana error library / Token account owner mismatch
Solana error: Token account owner mismatch (0x4)
The token account is owned by a different wallet than the one signing, so the program refuses to move the tokens.
Why it happens
- You are trying to spend from a token account that belongs to another wallet - often after switching accounts in the wallet extension.
- A delegated account was revoked, or the delegation expired.
- The interface passed the wrong token account for this mint.
How to fix it
- Confirm the active wallet in your extension matches the one that owns the tokens.
- Reconnect the wallet to the dApp so it re-reads the account list.
- If you were using a delegate, ask the owner to re-approve it.
What it looks like in the logs
Program TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA failed: custom program error: 0x4
Seeing this error right now? Paste your transaction signature and get the exact instruction, program and code that failed.
Diagnose my transaction