TOPIC / MODELS

OpenClaw model cost control: limits & fallback

Set daily and monthly limits, reduce context length, minimize tool mounting, and control fallback to keep costs predictable.

Best for

  • Already concerned about call cost and context growth
  • Want the most effective cost-reduction actions first
  • Want to put budget control into long-term config

Cost is not a later concern

Model costs often add up from the beginning. Wrong choices in context, tools, and fallback can quietly inflate bills before you notice.

What drives model cost

Costs in OpenClaw are usually amplified by:

  • Long conversation history
  • Tool definitions and tool calls
  • Large inputs and system prompts
  • Fallback triggers
  • Repeated reasoning in long chains

Set basic limits

openclaw config set ai.dailyLimit 1000
openclaw config set ai.monthlyBudget 50

Verify:

openclaw config list | grep ai\.

Five levers that matter most

  1. Shorten history — Avoid keeping unnecessary context across turns.
  2. Fewer tools — Only mount tools the task actually needs.
  3. Tighten fallback — Trigger fallback only on real failures.
  4. Single model first — Add complexity only when a single model is stable.
  5. Separate tasks — Split high-frequency vs high-value jobs.

JSON cost control example

{
  "costControl": {
    "enabled": true,
    "limits": {
      "perRequest": 0.05,
      "hourly": 5,
      "daily": 20,
      "monthly": 400
    },
    "actions": {
      "onHourlyLimit": "slowdown",
      "onDailyLimit": "alert_and_pause",
      "onMonthlyLimit": "stop"
    }
  }
}

Provider-side limits

Do not rely only on OpenClaw. Set hard usage limits in your provider dashboards:

Next steps

FAQ

Topic FAQ

Often it is context growth, frequent tool calls, and excessive fallback—not just model unit price.

No. Start with a few simple controls: shorter context, fewer tools, and fallback only when needed.