Free tool
AI Coding Rules Converter
Convert CLAUDE.md, AGENTS.md, Cursor rules, GEMINI.md and Copilot instructions between formats.
Runs entirely in your browser.
Common conversions
Your rules stay in your browser and are never uploaded.
Conversion output
What changed
A short summary appears here once there is something to convert.
Conversion notes
Notes about scope and anything that could not be carried over appear here.
Starting from scratch? Use the AI Coding Rules Generator to write the files from one project description, or see all free tools.
Guide
How to convert AI coding rules
Teams that use more than one AI coding agent end up with the same project rules written for each tool: a CLAUDE.md for Claude Code, an AGENTS.md for Codex and others, Cursor rules, a GEMINI.md and Copilot instructions. This converter moves an existing file from one of those formats to another without rewriting it. It reads the format you paste, keeps your text exactly as written, and changes only what the target format requires: frontmatter, filename and location.
- Pick a common conversion, or choose From and To. Auto-detect works when the file has recognisable frontmatter.
- Paste your file. The converted file updates as you type.
- Read the Conversion notes, then copy or download the file and save it at the path shown.
It is deterministic code, not an AI: the same input always gives the same output, nothing is summarised or reworded, and a file is never uploaded.
Rule formats compared
Checked against each vendor's documentation on . Formats change, so confirm against the linked source if something looks off.
| Tool | File | Scope mechanism | Project location |
|---|---|---|---|
| Claude Code | CLAUDE.md (and optional .claude/rules/*.md) | CLAUDE.md loads from the working directory and every directory above it, plus subfolder files on demand. Rule files can add paths globs. | Project root or .claude/CLAUDE.md; .claude/rules/ for path-scoped rules |
| AGENTS.md (Codex and others) | AGENTS.md | Directory-based: the closest AGENTS.md to the edited file wins. No globs or frontmatter. | Repository root, plus optional files in subfolders or packages |
| Cursor | .cursor/rules/*.mdc | Frontmatter: alwaysApply, globs (comma-separated) and description decide when a rule is used. | .cursor/rules/ (subfolders allowed) |
| Gemini CLI | GEMINI.md | Directory-based: global file, workspace folders and their parents, plus folders a tool touches. No frontmatter. | Project folders; global copy in ~/.gemini/ |
| GitHub Copilot | copilot-instructions.md and *.instructions.md | Repository-wide file, plus path-specific files with an applyTo glob. | .github/copilot-instructions.md and .github/instructions/ |
Cursor rules to CLAUDE.md
A Cursor Project Rule is an .mdc file in .cursor/rules with description, globs and alwaysApply frontmatter. Claude Code's project file is plain Markdown, so the frontmatter is removed and the rule text is kept. A rule with alwaysApply: true maps cleanly to a project-wide CLAUDE.md.
A rule scoped with globs has a closer match than a plain CLAUDE.md: a file in .claude/rules with a paths list, which Claude Code loads when it reads, writes or edits a matching file. The converter writes that by default and marks it approximate, because Cursor attaches a rule when a matching file is in context, which is not the same trigger. Cursor rules the agent decides to use, or that you only @-mention, have no Claude Code counterpart; the text is kept and the notes say it will apply to every session.
Cursor rules to AGENTS.md
AGENTS.md is plain Markdown with no metadata, and its scope comes from folder placement: the closest file to the edited file wins. An Always Apply rule becomes a root AGENTS.md. For a rule with globs, the converter suggests a subfolder only when every glob names the same literal folder, so src/components/**/*.tsx becomes src/components/AGENTS.md. That file then applies to everything under the folder, not just the matching files, and the notes say so. For anything more complex, such as **/*.tsx, it does not guess: the text is kept in a root file and the lost file scope is reported. Cursor reads AGENTS.md too, in the project root and in subdirectories.
CLAUDE.md to AGENTS.md
Both files are plain Markdown, so the text is carried over as written. What can differ is Claude-specific behaviour. Claude Code expands @path/to/file imports and strips block-level HTML comments before use; AGENTS.md readers show both as ordinary text. An @AGENTS.md line, the way a CLAUDE.md shares an AGENTS.md, is removed because it would point at itself. If you want to keep both files, Anthropic's documentation describes putting an @AGENTS.md import in a CLAUDE.md next to it.
AGENTS.md to CLAUDE.md
Claude Code reads AGENTS.md directly only when there is no CLAUDE.md in the working directory or above it, so creating a CLAUDE.md changes which file Claude uses. The two also build context differently: Claude Code concatenates CLAUDE.md files from the working directory and every directory above it, while for AGENTS.md the closest file wins. A pasted file carries none of that hierarchy, so the converter cannot tell where it lived or which parent and child files exist. Save the converted file in the same folder and review any nested AGENTS.md files separately.
Legacy .cursorrules migration
Cursor's help page describes the .cursorrules file in the project root as legacy and says it will be deprecated, without giving a date. Its migration steps are to create a new rule, paste the content, set it to Always Apply and delete the old file. The .cursorrules → Cursor Project Rule conversion does the first three steps for you and produces .cursor/rules/project.mdc with alwaysApply: true. Delete .cursorrules yourself once the new rule is saved. The tool accepts .cursorrules as input only and never creates a new one.
GEMINI.md and GitHub Copilot instructions
GEMINI.md is plain Markdown with no frontmatter; Gemini CLI gathers files from your workspace folders and their parents. Copilot's repository-wide file is .github/copilot-instructions.md, also plain Markdown. Copilot additionally supports path-specific files in .github/instructions whose names end in .instructions.md and which start with an applyTo glob, so a glob-scoped rule from Cursor or Claude Code can keep its scope there. Neither Cursor nor Copilot documents curly-brace patterns such as *.{ts,tsx}, so the converter expands them into separate globs for those two targets.
Why rule formats aren't always equivalent
The formats look alike because they are all Markdown, but they decide when a rule applies in different ways. Cursor decides in frontmatter: always, by file pattern, by the agent reading a description, or only when mentioned. CLAUDE.md, AGENTS.md and GEMINI.md decide by where the file sits in the folder tree, and Claude Code and Copilot add path-scoped files on top. A glob is a precise filter; a folder is a coarser one; a description has no equivalent in most tools at all.
So a conversion can be exact, approximate or lossy, and which one you get depends on the pair. Moving Always Apply rules between tools is usually exact. Moving glob rules keeps the patterns when the target has glob fields (Claude rule files, Copilot path-specific files, Cursor), though each tool defines for itself when a match triggers the rule. Into a folder the scope widens, and into a root file it is lost. Moving agent-decided or manual Cursor rules into anything else always loses that trigger. The converter keeps your text in every case and labels each note as exact, approximate or not carried over, so you can decide whether the result still does what you meant.
These files guide an agent; none of them enforces anything. Treat them as context, and use tests, linters and permissions for the rules that must never be broken.
Sources
- Claude Code: code.claude.com/docs/en/memory
- AGENTS.md (Codex and others): agents.md/
- AGENTS.md (Codex and others): developers.openai.com/codex/guides/agents-md
- Cursor: cursor.com/docs/context/rules
- Cursor: cursor.com/help/customization/rules
- Gemini CLI: geminicli.com/docs/cli/gemini-md/
- GitHub Copilot: docs.github.com/en/copilot/how-tos/configure-custom-instructions/add-repository-instructions
- GitHub Copilot: docs.github.com/en/copilot/reference/custom-instructions-support
Frequently asked questions
- How do I convert Cursor rules to CLAUDE.md?
- Pick Cursor Project Rule as the source and CLAUDE.md as the target, then paste your .mdc file. The converter removes the frontmatter and keeps your text unchanged. A rule with alwaysApply: true becomes a project-wide CLAUDE.md. A rule scoped with globs becomes a .claude/rules file with a paths list, which Claude Code loads when it reads, writes or edits a matching file. You can switch that off to get a plain CLAUDE.md instead.
- Can I convert CLAUDE.md to AGENTS.md?
- Yes. Both are plain Markdown, so your text is kept exactly as written. The converter flags what does not travel: @-imports that only Claude Code expands, block-level HTML comments that Claude Code strips, and an @AGENTS.md import line, which it removes because it would import itself. Because you paste a single file, it cannot know where the file lives or which other CLAUDE.md or AGENTS.md files exist, so save the result in the same folder as the original.
- Is .cursorrules deprecated?
- Cursor's help page calls the .cursorrules file in the project root legacy and says it will be deprecated. It gives no date, and the current system is Project Rules in .cursor/rules. This tool accepts .cursorrules as input and writes .cursor/rules/project.mdc with alwaysApply: true, which is the Always Apply setting Cursor's own migration steps use. It never generates a new .cursorrules file.
- Does AGENTS.md support globs?
- No. As documented on agents.md and in the Codex docs, AGENTS.md is plain Markdown with no required fields, no frontmatter and no glob matching. Scope comes from where the file sits: the closest AGENTS.md to the edited file wins. Cursor describes its AGENTS.md support the same way, as plain Markdown without metadata. When you convert a glob-scoped rule to AGENTS.md, the converter only moves it into a folder when every glob names the same literal folder; otherwise it keeps the text and tells you the file scope was lost.
- Can all rule scopes be converted exactly?
- No, and the converter does not pretend otherwise. Cursor's always, glob and manual rules, Claude Code's path rules, Copilot's applyTo and the folder-based scope of AGENTS.md, GEMINI.md and CLAUDE.md are different mechanisms. Where an exact equivalent exists it is used. Where it is close, the output is marked Approximate. Where there is none, such as a Cursor rule the agent decides to use, your text is kept and the Conversion notes say exactly what scope was not carried over.
- Does this upload my rules?
- No. The conversion runs in your browser with plain code: there is no AI model and no server call. What you paste is not sent to HistChat, not stored, not placed in the page address and not included in analytics. It disappears when you reload or close the page.
- Can I convert to GitHub Copilot instructions?
- Yes. Repository-wide rules become .github/copilot-instructions.md. A rule with globs can instead become a path-specific file at .github/instructions/NAME.instructions.md with an applyTo pattern. On GitHub.com, GitHub's documentation says path-specific instructions are supported for Copilot cloud agent and Copilot code review, so check which Copilot features you use.
- Can I download the converted file?
- Yes. Download saves the file under its own name, for example project.mdc or copilot-instructions.md. Browsers cannot create folders, so the full path to save it at, such as .cursor/rules/project.mdc, is shown next to the output with a Copy path button.
Related tools: AI Coding Rules Generator and MCP Config Generator.