Which AI Rules File Does Your Tool Read?
AGENTS.md, CLAUDE.md, .cursorrules & copilot-instructions
Every AI coding tool has grown its own "rules file": a plain .md you drop in your repo to tell the agent how to work. The confusing part is that they all picked different names. Claude Code wants CLAUDE.md, Copilot wants copilot-instructions.md, Cursor wants .cursor/rules, and a shared standard called AGENTS.md is spreading across all of them.
This is the map: which file each tool actually reads, where it lives, and the one thing that ties them together (they are all just Markdown).
The quick answer, by tool
| Tool | Rules file it reads | Where it lives |
|---|---|---|
| Claude Code | CLAUDE.md (also reads AGENTS.md) | Repo root, or ~/.claude/ for global rules |
| Cursor | .cursor/rules/*.mdc (legacy: .cursorrules) | .cursor/rules/ folder, or repo root for the legacy file |
| GitHub Copilot | .github/copilot-instructions.md (also AGENTS.md) | The .github folder at your repo root |
| OpenAI Codex | AGENTS.md | Repo root, or ~/.codex/ for global rules |
| Windsurf | .windsurf/rules/ (legacy: .windsurfrules) | .windsurf/rules/ folder, or repo root for the legacy file |
| Gemini CLI | GEMINI.md (also AGENTS.md) | Repo root |
Mappings shift as tools add support for the shared standard, so when in doubt, check your tool’s current docs. The trend is clear though: more and more tools also read AGENTS.md.
AGENTS.md: the cross-tool standard
If there is a winner emerging, it is AGENTS.md. It is an open format, stewarded under the Linux Foundation, and it is read by a growing list of agents including Cursor, Codex, Claude Code, Copilot, Windsurf, and Gemini. Think of it as a README written for agents instead of humans: the build steps, tests, and conventions an AI needs, kept out of your human-facing README.md.
For the full walkthrough of what goes inside one, see What are AGENTS.md and CLAUDE.md?
The tool-specific ones
- CLAUDE.md is Claude Code’s file. Same idea as AGENTS.md, just the Claude-specific name. Claude Code reads it from the repo root, and reads a global one from
~/.claude/. - .cursorrules and .cursor/rules/*.mdc are Cursor’s. The old format was a single
.cursorrulesfile at the repo root; the modern format is one or more.mdcfiles in.cursor/rules/(an.mdcfile is Markdown with a small header block for scoping). - copilot-instructions.md is GitHub Copilot’s, and it goes in
.github/. See What is copilot-instructions.md? for the specifics.
The thing they have in common: it is all Markdown
Strip away the different filenames and every one of these is a plain Markdown file. Headings, lists, and code blocks, nothing more. Here is a small AGENTS.md, and a CLAUDE.md or a .cursorrules looks the same:
# AGENTS.md
## Commands
- Build: npm run build
- Test: npm test
## Code style
- TypeScript, 2-space indent
- No default exports
## Boundaries
- Never edit files under /vendor Because they are all Markdown, you open, read, and edit any of them the same way. No special tool per format, no plugin. If you are new to the syntax, start with How to Write Markdown.
When you have several of them at once
Real repos often end up with more than one: an AGENTS.md, a CLAUDE.md, a .cursor/rules/ folder, maybe a .github/copilot-instructions.md. Keeping them consistent (and knowing which is the source of truth) is its own small chore. For that, see How to manage AI coding rule files, which is about organizing the whole pile rather than picking one.
Reading and comparing them with NoteLoom
To actually read these files side by side (or clean up the one your tool ignored because it was in the wrong place), you need an editor that opens a repo folder and renders Markdown. NoteLoom does exactly that, right in the browser: mount the folder, and its reading view shows AGENTS.md, CLAUDE.md, and the other .md rules files as clean formatted text, while the source view lets you edit and save back to disk.
To be clear about the boundaries: NoteLoom has no AI. It will not make Cursor or Claude follow your rules, and it does not connect to any coding tool. It just opens, displays, and saves the Markdown file itself. The rules, and whether the agent honors them, stay entirely between you and your tool.
How you use it: open app.noteloom.cc in Chrome / Edge / Arc, mount your project folder, open any .md rules file such as AGENTS.md or CLAUDE.md, and read or edit it. Saved straight to your disk, no cloud, no account.
FAQ
What is a rules file for an AI coding tool?
What is the difference between AGENTS.md and CLAUDE.md?
Which rules file does Cursor read?
Where does copilot-instructions.md go?
Are these files all just Markdown?
Can NoteLoom help me read and compare these files?
Can I do this with NoteLoom on my phone or in Safari?
Open your rules files and read them properly
Open NoteLoom in Chrome / Edge / Arc, mount your project folder, and read or edit any AGENTS.md, CLAUDE.md, or other .md rules file in a clean view. Saved straight back to your disk, no software to install and no account to sign up for.