How long should CLAUDE.md / AGENTS.md be? — Cursor Tips &…
    Neura Market
    Neura Market
    /Cursor
    Marketplace
    Directories
    Resources
    Cursor
    ChatGPTChatGPTClaudeClaudeGeminiGeminiCursorCursorGrokGrokPerplexityPerplexityDeepSeekDeepSeekCoPilotCoPilotStable DiffusionStable DiffusionMidjourneyMidjourney
    OverviewRulesPromptsMCPsAgentsGamesBlogVideosGuidesCoursesCommunityExtensionsTrending
    CursorBlogHow long should CLAUDE.md / AGENTS.md be?
    Back to Blog
    How long should CLAUDE.md / AGENTS.md be?
    ai

    How long should CLAUDE.md / AGENTS.md be?

    Clogmeter November 4, 2026
    0 views

    Every always-on instruction file costs tokens on every turn, and past a point it starts costing...


    title: "How long should CLAUDE.md / AGENTS.md be?" published: true tags: ai, claude, cursor, productivity canonical_url: https://clogmeter.vercel.app/guides/how-long-should-agents-md-be

    Every always-on instruction file costs tokens on every turn, and past a point it starts costing adherence too. Here is what Claude Code, Cursor and Codex actually document about size, plus a checklist for trimming.

    Originally published on clogmeter.vercel.app.

    Short answer: aim for a lean always-on file — roughly under 200 lines per CLAUDE.md (Anthropic’s documented target) and treat Cursor project rules as under 500 lines each, split by concern. There is no universal “perfect” line count. The real limit is whether the model still follows the rules that matter once system prompt, tools, skills and the task compete for the same attention budget.

    No invented benchmarks here. The numbers below come from vendor docs and published guidance as of late 2026.

    What the tools themselves say

    ToolFilePublished guidance
    Claude CodeCLAUDE.md / rulesTarget under 200 lines per file; longer files consume more context and reduce adherence. Imports organise files but still load with the parent.
    Cursor.cursor/rules / AGENTS.mdKeep rules under 500 lines; split large rules into focused files. Prefer references over pasting whole docs.
    OpenAI CodexAGENTS.mdCombined project instruction files are capped (default 32 KiB); overflow is truncated.

    Community write-ups often talk about a practical “~150 instruction” attention budget for frontier models before adherence drops — that is research/context, not a hard file limit. Your instruction file shares that budget with the agent’s system prompt and tool descriptions, so leave headroom.

    Why bloated files get ignored

    • Everything always-on costs every turn. Root CLAUDE.md / AGENTS.md is re-read at session start; fat files tax every message and every general-purpose subagent.
    • Markdown is advisory. Claude Code docs treat memory files as context, not enforced config. A “never” in prose can still be skipped; hooks and permissions enforce must-holds.
    • Conflicts cancel each other. Duplicate or contradictory always/never rules across files make the model pick arbitrarily.
    • Long sessions compress early rules. Mid-thread, package-manager or style rules often shrink first while code stays — which feels like “Cursor/Claude is ignoring my rules.”

    A practical size checklist

    1. Measure first. In Claude Code, run /context (and /doctor for trim proposals). For any stack, paste the files into Clogmeter to see token weight vs common windows and spot duplicates/conflicts.
    2. Keep always-on content tiny. Project identity, hard constraints, build/test commands, and pointers. Delete anything the agent can discover by reading the repo.
    3. Move procedures to skills. Release checklists and long how-tos should load on demand, not on every prompt.
    4. Scope directory rules. Nested AGENTS.md / path-scoped Cursor or .claude/rules files beat one giant root file.
    5. Enforce never-rules outside markdown. If ignoring it once would hurt, use a hook, linter or CI check.
    6. One source of truth. Prefer a canonical AGENTS.md with thin CLAUDE.md / Cursor adapters instead of divergent copies.

    How long is “too long” in practice?

    If the root file is hundreds of lines, mixes architecture essays with one-off workflows, or repeats the same rule in three places, it is already too long for reliable adherence — even if the model still “sees” the file. Vendors warn that longer instruction files reduce compliance before hard truncation kicks in (Codex’s 32 KiB cap being the blunt case).

    A useful rule of thumb many teams use: if you would not ask a new teammate to memorise the whole file before their first PR, do not force the agent to either. Make the root file the map; put the territory in scoped docs and skills.


    If you want to see where your own AGENTS.md, CLAUDE.md or Cursor rules spend tokens, I built a free browser-only checker that also flags duplicates and always/never conflicts: Clogmeter.

    Tags

    aiclaudecursorproductivity

    Comments

    More Blog

    View all
    How I stop AI coding agents breaking my projectai

    How I stop AI coding agents breaking my project

    I like AI coding agents. I do not like when they rewrite a file that was already fine, hard-code a...

    T
    Theodore Creates Co.
    1
    2026 MCP Gateway Benchmark: Cutting Cursor and Claude Token Bloat by 85% with Zero-Trust AST Securitymcp

    2026 MCP Gateway Benchmark: Cutting Cursor and Claude Token Bloat by 85% with Zero-Trust AST Security

    Connecting 3 to 5 Model Context Protocol (MCP) servers (GitHub, Postgres, Linear, Slack, Notion) into...

    N
    Neon Innovation Lab
    2
    Too many agent skills? What they cost in context and how to pruneai

    Too many agent skills? What they cost in context and how to prune

    How Claude Code, Codex and Cursor load skills, what really costs context, and how to audit, prune and scope installed skills.

    E
    Eliran Kotzero
    1
    How I Use Cursor and AI Coding Agents to Ship Features That Actually Last in Productionai

    How I Use Cursor and AI Coding Agents to Ship Features That Actually Last in Production

    I use Cursor almost every day. The hard part is not generating code. It is giving the agent enough context, constraints, and a plan so the feature still makes sense after it reaches production.

    A
    Aqib
    2
    What is Model Context Protocol (MCP) and how to use itai

    What is Model Context Protocol (MCP) and how to use it

    Learn how the Model Context Protocol standardizes AI integrations, with a look at connecting Claude and Cursor to custom environments.

    W
    WaterShow
    Talk to Your Coding Agent: What Cursor's Realtime Voice Chat Actually Changescursor

    Talk to Your Coding Agent: What Cursor's Realtime Voice Chat Actually Changes

    Cursor's November 6 changelog entry is short — "Voice Chat with Agents" — but it changes the shape of...

    野
    野鹤
    1

    Stay up to date

    Get the latest Cursor prompts, rules, and resources delivered to your inbox weekly.

    Neura Market LogoNeura Market

    Discover the best AI prompts, plugins, and resources for Cursor and more.

    Content Types

    • Rules
    • Prompts
    • MCPs
    • Agents
    • Games
    • Blog
    • Videos
    • Guides
    • Courses
    • Community
    • Extensions

    Platforms

    • ChatGPT Directory
    • Claude Directory
    • Gemini Directory
    • Cursor Directory
    • Grok Directory
    • Perplexity Directory
    • DeepSeek Directory
    • CoPilot Directory
    • Stable Diffusion Directory
    • Midjourney Directory
    • All Directories

    Resources

    • Blog
    • Documentation
    • Help Center
    • Marketplace

    Legal

    • Privacy Policy
    • Terms of Service

    © 2026 Neura Market. All rights reserved.

    |

    Not affiliated with any AI platform vendors.

    Neura Market

    Custom AI Systems & Services

    Our team of experienced AI builders will help build custom AI systems, workflows, and solutions.

    Request custom work

    Ready-made automations for this

    Workflows from the Neura Market marketplace related to this Cursor resource

    • Full Blog Content Automation with GPT-4, Claude & Ghost CMS Publishern8n · $24.99 · Related topic
    • AI Blog Post Journalist: Perplexity for Research, Anthropic Claude for Blogn8n · $9.99 · Related topic
    • Generate XML System Messages for AI Agents Using Claude 4 Sonnetn8n · $9.99 · Related topic
    • Multi-Platform Price Finder: Scraping Prices with Bright Data, Claude AI & Telegramn8n · $24.99 · Related topic
    Browse all workflows