AGENTS.md: What It Is, How It Differs From CLAUDE.md, and How to Write One
A 369-comment, year-old Claude Code feature request for AGENTS.md just closed as completed, not through native parsing but through a documented @-import and a new /import command. Here's what actually shipped, and how to write your own file.
This site's own CLAUDE.md is a single line, `@AGENTS.md`, using the exact interop pattern this guide covers, not a hypothetical example assembled for the post.
AGENTS.md is an open, tool-agnostic Markdown file, stewarded by the Linux Foundation's Agentic AI Foundation, that gives AI coding agents build, test, and convention context a README doesn't carry. On August 17, 2026, Anthropic closed a 369-comment, year-old Claude Code feature request for it, not by reading it natively, but through a documented `@AGENTS.md` import and a new `/import` command.
What Is AGENTS.md?
AGENTS.md is a plain Markdown file, no required schema, no frontmatter, that sits at a repository root and gives AI coding agents the context a README is written for humans, not agents, to skip: build commands, test invocation, code style, and project-specific conventions. The agents.md site frames the split directly: keep READMEs "concise and focused on human contributors" and give agents "a clear, predictable place for instructions" instead.
It launched in August 2025, backed jointly by OpenAI, Google's Jules team, Cursor, Factory, and Amp. Community tracking of path:AGENTS.md on GitHub put adoption at roughly 20,000 projects within days of launch; by the time this guide was written, agents.md put that figure at over 60,000. In December 2025, the Linux Foundation formed the Agentic AI Foundation (AAIF) to steward it long-term, alongside Anthropic's Model Context Protocol and Block's goose, with Anthropic, AWS, Google, Microsoft, and OpenAI as platinum members.
More than 25 tools read it today, including OpenAI Codex, GitHub Copilot, Cursor, Google's Gemini CLI and Jules, JetBrains Junie, Zed, Warp, Aider, and Cognition's Devin and Windsurf. A minimal file looks like this:
# AGENTS.md## Dev environment tips- Run `pnpm install` at the repo root before anything else.- Use `pnpm dlx turbo run where <project_name>` to jump to a package.## Testing instructions- CI runs everything under `.github/workflows/`; mirror that locally with `pnpm test`.- Fix any test or type error until the whole suite is green.## PR instructions- Title format: `[<project_name>] <Title>`- Run `pnpm lint` before every commit.For monorepos, nested AGENTS.md files inside subprojects take precedence over the root file for that subtree, the same override model most tool-specific formats already use.
Why Not Just Use CLAUDE.md, .cursorrules, or copilot-instructions.md?
Every major coding agent shipped its own file before AGENTS.md existed, and most still default to reading their own first. The practical problem shows up the moment a repository has contributors on different tools: instructions written for one agent are invisible to the others unless someone duplicates them by hand.
| File | Read by | Always loaded? | Notes |
|---|---|---|---|
AGENTS.md | 25+ tools (Codex, Cursor, Copilot, Jules, Gemini CLI, Aider, Devin, Windsurf, Junie, Zed, Warp) | Yes, at session start | Open format, no required fields, nested files override by directory |
CLAUDE.md | Claude Code only | Yes, at session start | Supports @path imports, org/user/project/local scopes |
.cursorrules / .cursor/rules/ | Cursor only | Yes | Cursor also reads AGENTS.md directly as a supporting tool |
.github/copilot-instructions.md | GitHub Copilot only | Yes | Copilot also reads AGENTS.md directly as a supporting tool |
SKILL.md (Claude Code Skills) | Claude Code only | No, loaded on demand | Task-specific procedures, not always-on project context |
The last row is worth separating out on its own, since it's a common point of confusion (it's the second-most-common autocomplete pairing after AGENTS.md vs CLAUDE.md): a SKILL.md packages a specific, repeatable workflow that Claude Code loads only when it decides that workflow is relevant to the current task. AGENTS.md and CLAUDE.md are the opposite, both load in full at the start of every session, whether or not the current task needs them. Skills are for "how to do X"; AGENTS.md is for "what you need to know before doing anything here."
How Claude Code Actually Handles AGENTS.md
This is the part worth getting precise about, because the honest answer is more interesting than "it just works now."
Claude Code still reads only CLAUDE.md at session start. As of Claude Code's current documentation, it does not parse AGENTS.md natively. What changed is that Anthropic officially documented and endorsed two ways to bridge the gap, and shipped a third:
- The `@AGENTS.md` import. Create a
CLAUDE.mdwhose entire content is@AGENTS.md, and Claude Code loads the imported file's full contents at launch. Tool-specific instructions can go below the import line. - A symlink.
ln -s AGENTS.md CLAUDE.mdworks on macOS and Linux with no Claude-specific content needed. Windows requires Administrator privileges or Developer Mode for symlinks, so the@AGENTS.mdimport is the documented fallback there. - The `/import` command, shipped in Claude Code v2.1.213, reads a supported coding agent's configuration,
AGENTS.mdincluded, and carries over not just instructions but MCP servers, commands, subagents, and skills into their Claude Code equivalents. Separately, running/initwithCLAUDE_CODE_NEW_INIT=1set also readsAGENTS.md(along with.devin/rules/,.windsurf/rules/, and.clinerules) when generating a newCLAUDE.md.
That's the whole shape of the current answer: interop by convention and tooling, not by the runtime reading a second file format. It's enough to close the original request, though. GitHub issue #6235, "Feature Request: Support AGENTS.md.", was opened on August 21, 2025, three days after AGENTS.md itself launched. It ran for 369 comments, including a community member posting the exact @AGENTS.md workaround above within the first three days as the practical fix people were already shipping. Anthropic closed it as completed on August 17, 2026, almost exactly one year later.
What the closure doesn't mean: a narrower, more literal version of the same ask, issue #34235, "support AGENTS.md as a native context file alongside CLAUDE.md" opened March 14, 2026, remains open. The distinction the two threads draw is real: #6235 asked for interoperability and got it through import tooling; #34235 asks for Claude Code's own file-discovery step to read AGENTS.md directly, with no CLAUDE.md in the loop at all, and that hasn't shipped.
How to Write Your Own AGENTS.md
The format has no required fields, so the risk isn't getting the syntax wrong, it's writing something too generic to change agent behavior. Anthropic's own advice for CLAUDE.md, which loads through the identical context mechanism, applies just as directly here: specific, concise, verifiable instructions outperform vague ones. "Use 2-space indentation" changes behavior; "format code properly" doesn't.
Start from what a new contributor would actually ask
Write down what you'd otherwise re-explain to a human joining the project this week: exact build and test commands, where a specific kind of code lives, the PR title convention, anything a code review has caught the same mistake on twice.
Keep it short and let nested files carry the rest
A single sprawling root file loses adherence the same way an oversized CLAUDE.md does. In a monorepo, put shared conventions at the root and package-specific detail in nested AGENTS.md files, they override the root for their own subtree.
Cover the sections that generalize across tools
Since 25+ tools read this file, avoid instructions specific to one agent's UI or command set. Dev environment setup, test invocation, lint/format commands, and commit or PR conventions read the same regardless of which agent opens the file.
Wire it into Claude Code explicitly
Neither AGENTS.md nor CLAUDE.md appears automatically for the other tool. Add the @AGENTS.md import (or the symlink) so Claude Code actually loads it, see the next section for the exact pattern.
Confirm it loaded before trusting it
Run /context in a Claude Code session and check the Memory files list. If CLAUDE.md isn't there, the import silently didn't happen, and the instructions you just wrote aren't reaching the model.
Migrating an Existing CLAUDE.md to AGENTS.md
If a CLAUDE.md already exists and carries content other tools would also benefit from, move the tool-agnostic parts into AGENTS.md and leave CLAUDE.md as a thin wrapper: the import, plus anything genuinely Claude Code-specific underneath it. This is the exact pattern from Anthropic's own documentation:
@AGENTS.md## Claude CodeUse plan mode for changes under `src/billing/`.Three steps to get there from an existing, single-tool CLAUDE.md:
- Copy the tool-agnostic sections, dev environment, testing, PR conventions, into a new
AGENTS.mdat the repo root. - Replace
CLAUDE.md's content with@AGENTS.md, followed by anything that only makes sense for Claude Code specifically (plan-mode rules, subagent configuration, hook references). - Run
/contextto confirmCLAUDE.mdstill appears under Memory files, then open the file with/memoryto spot-check that the imported content rendered as expected.
The same repository that backs this guide does exactly this: its CLAUDE.md is the single line @AGENTS.md, and the actual build rules, the Next.js version notes, the GEO content requirements for new posts, live in AGENTS.md where Cursor, Codex, or any other AGENTS.md-reading tool can see them too.
Frequently Asked Questions
Does Claude Code read AGENTS.md natively?
No. Claude Code still only reads CLAUDE.md at session start. What Anthropic shipped instead is official support for interop: a documented @AGENTS.md import line, a symlink alternative, /init reading AGENTS.md when CLAUDE_CODE_NEW_INIT=1 is set, and a /import command (v2.1.213+) that pulls an existing AGENTS.md into a matching CLAUDE.md along with MCP servers, commands, and skills. That combination was enough for Anthropic to close the original GitHub feature request (#6235, opened August 21, 2025) as completed on August 17, 2026, even though Claude Code's file-discovery step never changed.
What's the difference between AGENTS.md and a Claude Code SKILL.md file?
AGENTS.md and CLAUDE.md both load in full at the start of every Claude Code session, whether the current task needs them or not. A SKILL.md packages one specific, repeatable workflow and loads only when Claude Code decides that workflow is relevant to what you're currently asking for. Use AGENTS.md for always-true project context (build commands, conventions); use a skill for a procedure that only matters some of the time.
Can one AGENTS.md file work across Claude Code, Cursor, and GitHub Copilot?
Cursor and GitHub Copilot are both listed as supporting tools on agents.md and read AGENTS.md directly, no extra step needed. Claude Code is the exception among the major agents here: it needs an explicit @AGENTS.md import or a CLAUDE.md symlink, since its own file-discovery step only looks for CLAUDE.md.
Is AGENTS.md an official standard or one vendor's convention?
As of December 2025, it's stewarded by the Agentic AI Foundation (AAIF) under the Linux Foundation, alongside Anthropic's Model Context Protocol and Block's goose. Platinum members include Anthropic, AWS, Bloomberg, Cloudflare, Google, Microsoft, and OpenAI, so despite originating at OpenAI, it now has multi-vendor governance rather than sitting under one company.
References
- agents.md: official specification and adopter list
- GitHub Issue #6235: Feature Request: Support AGENTS.md (closed completed, anthropics/claude-code)
- GitHub Issue #34235: support AGENTS.md as a native context file alongside CLAUDE.md (open, anthropics/claude-code)
- Claude Code Docs: How Claude remembers your project (CLAUDE.md, AGENTS.md import, /import)
- Linux Foundation: Announcing the Agentic AI Foundation (AAIF)