Solana error code lookup

Decode custom program error: 0x…, Anchor errors and Solana JSON-RPC errors. Paste the error or the program logs and get the program, the error name and, for common errors, what it means and what to do.

Free, no sign-up, nothing to connect. Works offline from a bundled list; we do not look anything up on-chain.

Most searched codes

Why the same code means different things

A custom program error is a number chosen by the program that failed. 0x1 is “not enough SOL” in the System Program and “insufficient funds” (not enough tokens) in SPL Token. Programs using Anchor-style numbering start their own errors at 6000 (0x1770), so 0x1771 (6001) is slippage in Jupiter v6 and something else entirely in pump.fun. Codes 100 to 5999 are Anchor framework errors.

How to tell which program failed

  1. Open the failed transaction in an explorer (or the simulation result in your code) and read the program logs.
  2. Find the line Program <address> failed: custom program error: 0x…. If several programs failed with the same code, the first one listed is the deepest call, the one that raised it.
  3. Look the code up for that program. Error processing Instruction 2 is a zero-based index, so it points to the third instruction (often the first one after two Compute Budget instructions).

Error codes by program

41 programs and the Anchor framework, 618 distinct codes.

Solana JSON-RPC errors

For developers and agents

GET https://rugsight.rugsight.workers.dev/api/errors/decode?q=<error text>&program=<program id> returns the same result as JSON. Free, no key.

Swapping a token you do not know? A free Rugsight check shows mint and freeze authority, Token-2022 extensions, holder concentration and liquidity before you trade.

Data: program error lists from published IDLs (solana-idls 1.2.1, MIT) and the System, SPL Token, Token-2022 and Associated Token Account source code, snapshot 2026-11-16. Programs can be upgraded and add or change errors; the failing program's current IDL is the final word.