When compiling programs with newer versions of the solana CLI my binary is ~50% larger than before? This is an issue for upgrading old programs built with older version of the CLI. (A program built with 1.9.16 is 1.1mb, the same program built with 1.10.2 is 1.5mb)

1 Answer 1


There's no good answer to this unfortunately, except "this can happen". Typically it's due to additional dependencies that are brought in, or changes to the compiler that result in more code emitted. You can try a later version to see if it reduces the size of the final binary. And if not, you'll soon be able to increase the size of your program once the ExtendProgram instruction lands: https://github.com/solana-labs/solana/issues/26385

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.