Back to components
ComponentAI & ChatFree

Token Budget Bar React component

A compact context budget island with used and reserved tokens, expandable breakdown and near-limit or exceeded states.

About the Token Budget Bar component

A compact context budget island with used and reserved tokens, expandable breakdown and near-limit or exceeded states.

When to use it

Show context consumption alongside an AI conversation.

Reserve room for output before the context window fills.

Installation

Add the Token Budget Bar component to your project with the shadcn CLI. It lands in components/token-budget-bar.tsx as plain React + Tailwind CSS source you own and can edit.

Install
Copied!
npx shadcn@latest add @reactframe/token-budget-bar

Or copy the source by hand and install its dependencies:

Install
Copied!
npm install motion lucide-react clsx tailwind-merge

More AI & Chat components

Reasoning Indicator
Free
AI Mail Composer
Free
Neural Pulse Loader
Free
Hover Reply Toolbar
Free
Inline Rewrite Helper
Free
Next Best Action Card
Free