Skip to main content

AGENTS.md (format)

An open, unschematized markdown format for providing cross-agent project instructions. Named after the file it lives in: AGENTS.md at the repo root. Website: agents.md Steward: Agentic AI Foundation / Linux Foundation

Origin

Emerged from multi-vendor collaboration: OpenAI Codex, Amp, Jules (Google), Cursor, Factory. OpenAI Codex first popularized the format; the Agentic AI Foundation now stewards it as a neutral open standard. Adopted by 60k+ open-source projects as of 2026.

Format Rules

  • Plain markdown. No schema. No required fields.
  • Any heading structure is valid.
  • Closest file in directory tree wins (nested-AGENTS.md for monorepos).
  • User chat prompts override file contents.

Implementations by Tool

Each tool implements its own discovery and layering on top of the format:

Migration

Aider (.aider.conf.yml) — requires opt-in:

Multi-file Strategies

The base format is single-file. Tools extend it differently:
  • Codex: AGENTS.override.md layering + project_doc_fallback_filenames for alternate names
  • OpenCode: instructions field in opencode.json — glob patterns, multiple files, remote URLs
  • Claude Code: CLAUDE.md with @path/to/file.md imports
  • Manual: Teach agent to lazy-load referenced files via @docs/file.md references in instructions