Google · Antigravity IDE · Antigravity CLI (replaced Gemini CLI) · Antigravity app
Google Antigravity rules files explained
Which instruction files Google Antigravity reads (AGENTS.md, GEMINI.md, .agents/rules/*.md), where to put them, and how to convert from other agents.
Files Antigravity reads
AGENTS.mdGEMINI.md.agents/rules/*.md
AGENTS.md: Yes: AGENTS.md or GEMINI.md at any directory level, always on.
Skills folders: .agents/skills/, ~/.gemini/config/skills/
Who reads what
| Agent | Rules files | AGENTS.md |
|---|---|---|
| Claude | CLAUDE.md, .claude/rules/*.md | Only when no CLAUDE.md / CLAUDE.local.md exists (default, v2.1.277+); or import it with @AGENTS.md |
| Codex | AGENTS.md, AGENTS.override.md | Yes: global ~/.codex/AGENTS.md plus one AGENTS.md (or AGENTS.override.md) per directory from the repo root down |
| Cursor | .cursor/rules/*.mdc, AGENTS.md, .cursorrules (legacy) | Yes, in the project root and in subdirectories (nested files combine) |
| Copilot | .github/copilot-instructions.md, .github/instructions/*.instructions.md, AGENTS.md | Yes on most surfaces (cloud agent, CLI, VS Code chat, code review); not Copilot Chat on GitHub.com |
| Antigravity | AGENTS.md, GEMINI.md, .agents/rules/*.md | Yes: AGENTS.md or GEMINI.md at any directory level, always on |
Antigravity rule scopes, triggers and limits
Antigravity combines rules from every scope rather than replacing them, and more specific directory rules win on conflicts. When it reads or edits a file it walks up to the workspace root, loading AGENTS.md or GEMINI.md, .agents/AGENTS.md, and .agents/rules/*.md at each level. Global rules live in ~/.gemini/AGENTS.md or GEMINI.md (always on, no frontmatter) and ~/.gemini/config/rules/*.md (frontmatter required).
Every file in a rules/ folder must start with YAML frontmatter and a valid trigger: always_on, model_decision, glob or manual. Google warns that a missing trigger or a camelCase value like alwaysOn makes Antigravity silently discard the rule. model_decision rules need a description, and only the path and description are injected until a task matches. glob rules need globs, and manual rules load only when @-mentioned. Only immediate .md children of .agents/rules/ are scanned; nested folders need .agents/rules.json.
Limits: a single rule file is truncated past 24,000 bytes, and all global and always_on rules share a 20,000-token budget.
Source: antigravity.google · Checked Oct 24, 2026
Guides, pricing & comparisons
How to add an MCP server to Google Antigravity
How to migrate from Gemini CLI to Antigravity CLI
Portable agent skills: one SKILL.md for every coding agent
Antigravity CLI (agy): install, sign in, modes and commands
Google Antigravity on Windows: install, WSL, sandbox and fixes
Antigravity skills: create, store and run SKILL.md skills
Fix spawn npx ENOENT when starting an MCP server
MCP connection closed: find why a server will not connect
Gemini 4 Carbon in coding tools: API pricing, Cursor and CursorBench
Google Antigravity vs Claude Code: documented features compared
Google Antigravity vs Cursor: documented features compared
Google Antigravity pricing, quota and rate limits
AGENTS.md vs CLAUDE.md vs Cursor rules
AGENTS.md templates for Laravel and Next.js
MCP servers that work in every coding agent