Nexus

Algorand "dynamic cost budget exceeded" app call error

Short answer: The app call ran more opcodes than the budget allows. A single app call has a budget of 700 and expensive opcodes (hashing, EC math) use it up fast.

What the node printed

Pattern:

logic eval error: dynamic cost budget exceeded, executing <opcode>: local program cost was <n>. Details: app=<APP_ID>, pc=<PC>, ...

Captured verbatim from a testnet node on 2026-12-03:

logic eval error: dynamic cost budget exceeded, executing intc_0 (1): local program cost was 700. Details: app=778835193, pc=116, opcodes=keccak256; pop; intc_0 // 1

Why it happens

The test app looped over keccak256, an expensive opcode, and the node stopped it with "dynamic cost budget exceeded ... local program cost was 700". The 700 in the message is the per-call budget shown by the node in this capture. The budget is shared across the app calls in one atomic group. Measured on this test app, whose loop needs about 2600 units: the call alone failed, with one extra plain app call in the group it still failed, and with four extra plain app calls (5 x 700 = 3500) it passed. Simulate with extraOpcodeBudget: 5000 also passed.

How to fix it

const req = new algosdk.modelsv2.SimulateRequest({ txnGroups: [...], extraOpcodeBudget: 5000, allowEmptySignatures: true });

Method: this message was produced on purpose against a live testnet node (https://testnet-api.algonode.cloud) on 2026-12-03. Message wording can change between node versions. All errors: index · errors.json.