AGENTS.md — the guide
What the file is, which tools actually read it, how Codex applies it, and a starter template you can drop into a repo today. Every claim on this page is sourced and dated.
What is AGENTS.md?
AGENTS.md is an open convention for a markdown file at the root of a repository that gives coding agents project-specific instructions — build commands, conventions, boundaries. OpenAI initiated it in August 2025; it is now governed by the Linux Foundation's Agentic AI Foundation alongside MCP, and it appears in more than 60,000 open-source repositories.
The idea is simple: every coding agent needs the same orientation before it touches a codebase — how to build it, how to test it, what to leave alone — so that guidance goes in one predictably named markdown file at the repository root instead of being repeated per session or per tool. Governance has since moved to the Linux Foundation's Agentic AI Foundation (AAIF), which also stewards MCP, contributed by Anthropic, and goose, contributed by Block.The Linux Foundation's announcement puts adoption at more than 60,000 open-source projects.
Which tools read AGENTS.md?
Nine tools are on the Linux Foundation's official list: Amp, Codex, Cursor, Devin, Factory, Gemini CLI, GitHub Copilot, Jules, and VS Code. Wider support — including Claude Code and Windsurf — is widely reported but does not appear on the Linux Foundation's list, so treat those as reported rather than officially confirmed.
Per the Linux Foundation announcement · verified Jul 9, 2026
Claude Code and Windsurf are widely reported to read AGENTS.md too, but neither appears on the Linux Foundation's list. That list is the only official roster, so we keep the two groups separate — LF-listed above, reported-but-unlisted noted here — until an equally authoritative source settles it. When the foundation updates its list, this page updates the same week.
How does Codex use AGENTS.md?
Codex reads AGENTS.md from the root of the repository it is working in at the start of a session and applies the contents as project instructions. Whatever you put there — build commands, conventions, boundaries — shapes how the agent works on your code without you restating it in every prompt. The file is plain markdown; no schema or special syntax is required.
That description is deliberately conservative. Codex now spans several surfaces — CLI, IDE extensions, cloud, and the ChatGPT desktop app — and behavior details such as nesting, precedence between multiple instruction files, and interaction with per-user config deserve verification against real sessions rather than paraphrases of other people's posts. As we verify each behavior, it gets documented here with a date on it.
What goes in a starter AGENTS.md?
Four things: a short project overview, the exact commands to install, build, test, and lint, the conventions the codebase follows, and the boundaries the agent must respect. Keep it under a screen or two — the file is instructions, not documentation. Here is a generic starting point you can adapt to any stack.
# AGENTS.md
## Project overview
[One or two sentences: what this project is, primary language and framework.]
## Commands
- Install dependencies: `[your install command]`
- Build: `[your build command]`
- Run tests: `[your test command]`
- Lint / format: `[your lint command]`
## Conventions
- Code style: [formatter or linter, and where its config lives]
- Commit messages: [your convention]
- Layout: [where source, tests, and assets live — one line each]
## Boundaries
- Do not edit: [generated files, vendored code, lockfiles, migrations]
- Secrets live in [location]; never hard-code or commit them.
- Ask before: [deleting files, changing public APIs, altering CI]This is a generic template, not sample output from any tool. Replace the placeholders, delete sections that do not apply, and resist the urge to pad it — a short file that is always true beats a long one that drifts out of date.
AGENTS.md vs CLAUDE.md vs copilot-instructions
Three files, one job: standing instructions for a coding agent, versioned with the repo. The difference is scope — one is a cross-tool standard with a foundation behind it, and two are tool-specific conventions.
| File | Read by | Status |
|---|---|---|
AGENTS.md | Cross-tool — the nine tools on the Linux Foundation's official list, including Codex, Cursor, GitHub Copilot, Gemini CLI, and VS Code | Open standard governed by the Linux Foundation's Agentic AI Foundation; 60,000+ open-source repos |
CLAUDE.md | Claude Code (Anthropic) | Tool-specific instructions file; Claude Code's AGENTS.md support is widely reported but not on the LF list |
.github/copilot-instructions.md | GitHub Copilot | Tool-specific instructions file; Copilot also appears on the LF list of AGENTS.md readers |
People already treat these as one decision — "agents.md vs claude.md vs copilot-instructions.md" comes straight from Google autocomplete (pulled live July 9, 2026). The convergence point is AGENTS.md: it is the only one of the three with a standards body behind it and a published multi-vendor reader list.
Do you need an AGENTS.md file to use Codex?
No. AGENTS.md is a convention, not a requirement — Codex and every other tool on the Linux Foundation's list run fine without it. The file earns its place on any project you return to more than once: it replaces the project context you would otherwise paste into every session, and it is version-controlled alongside the code it describes.
Is AGENTS.md an OpenAI product?
OpenAI initiated the convention in August 2025, but it no longer belongs to OpenAI. The Linux Foundation's Agentic AI Foundation governs it as an open standard, alongside MCP (contributed by Anthropic) and goose (contributed by Block), per thefoundation's announcement. That neutral home is the point: the same file is meant to work across competing coding agents.
Changelog for this page
Every edit to this reference, newest first. This is what "living document" means.
Sources
- Linux Foundation — "Linux Foundation Announces the Formation of the Agentic AI Foundation" — governance, founding contributions (MCP, goose, AGENTS.md), the 60,000+ adoption figure, and the official tool list. Verified Jul 9, 2026.
- OpenAI Codex documentation (learn.chatgpt.com/docs) — the official docs home; developers.openai.com/codex now redirects here. Verified Jul 9, 2026.
- openai/codex on GitHub — the open-source Codex CLI. Verified Jul 9, 2026.
- Google autocomplete, pulled live July 9, 2026 — the "agents.md vs claude.md vs copilot-instructions.md" comparison demand.
Codex Insider is independent and not affiliated with OpenAI, Anthropic, GitHub, or the Linux Foundation.