Custom program error

0x7d62006

Appears in logs as custom program error: 0x7d6

Anchor

ConstraintSeeds

“A seeds constraint was violated”

The PDA passed does not match the address derived from the seeds and bump in the account constraint. This is the most common Anchor error.

Common causes

  • Client derives the PDA with different seeds (wrong order, wrong encoding, string vs bytes, little- vs big-endian numbers).
  • Using a different program id for derivation than the program being called.
  • Passing a canonical bump when the program stored a different bump, or vice versa.
  • Seeds depend on another account (for example seeds = [b"vault", user.key().as_ref()]) and the wrong user was passed.

How to fix it

  • Use the PDA tool on this site: enter the program id and seeds exactly as the Rust code writes them and compare with what your client derives.
  • Encode numbers as the Rust side does (u64 → 8 bytes little-endian via to_le_bytes()).
  • Let the generated client resolve PDAs automatically when the IDL includes seed definitions.

Decode another error

Try: