Egor Urvanov

AGENTS.md

Harness

AGENTS.md is a shared instructions file for a project that many agents read. Codex, Cursor, Copilot, Windsurf, OpenCode and others use it, and Claude Code does when the project has no CLAUDE.md, so it is a vendor-neutral counterpart of CLAUDE.md.

AGENTS.mdCLAUDE.mdAGENTS.mdone file per projectCodexCursorHermes AgentCLAUDE.md · Claude Codeimports @AGENTS.mdin subfolders the nearest file wins● model, people, systems, data  ● agent and harnessOne instructions file read by different agents

Frequently asked questions

What is AGENTS.md?

A shared instruction file for different agents: commands, style, prohibitions.

Which agents read AGENTS.md?

Codex, Cursor, Copilot, Windsurf, OpenCode and others. Claude Code reads AGENTS.md when the project has no CLAUDE.md; Gemini CLI does after the name is added to the context.fileName setting. A per-agent table is in the article, checked 15.11.2026.

AGENTS.md or Cursor rules?

Cursor reads both AGENTS.md and its own rules in .cursor/rules. AGENTS.md is a shared file for different agents, at the root and in subfolders, with no modes; rules in .cursor/rules are .mdc files that can apply always, by description, by file pattern or manually. Cursor docs advise replacing the legacy .cursorrules with a rule in Always Apply mode.

How is AGENTS.md different from spec.md?

AGENTS.md sets rules for the whole project and enters every agent session. spec.md describes one task — requirements and done criteria — and lives until the task is closed.

Source: AGENTS.md official site

Read more: AGENTS.md, CLAUDE.md and spec.md: what goes whereCursor rules vs AGENTS.md: what goes where

Where it appears · 10

More 5

Related terms

Whole glossary

© 2026 Egor Urvanov