Skip to content
BENIBIX Learn

DISABLE_COST_WARNINGS

AI⌨️ Claude CodeConfiguration

Also known as DISABLE_COST_WARNINGS=1

Set to 1, it hides the cost warning messages.

Think of it like

It is like you turn off the beep that says a meter is high.

Example

Emma's script reads Claude's output, and a cost warning broke the parse. She sets this, and the output stays clean.

Why it matters

A warning in the wrong place can break a script that reads the output.

Definition

DISABLE_COST_WARNINGS set to 1 hides the messages that warn you about cost. The cost itself does not change. Only the warning goes away.

Example code

bash
export DISABLE_COST_WARNINGS=1
claude -p "Summarize the log"
Keep cost notes out of a script's output.

Common mistake

Thinking it saves money. The cost is the same. You just stop seeing the note.

Key takeaways

  1. 1
    Hides warnings. Only.
  2. 2
    Cost unchanged. Same spend.
  3. 3
    Clean output. For scripts.