Skip to content

Rules

Open in ChatGPT ↗
Ask ChatGPT about this page
Open in Claude ↗
Ask Claude about this page
Copied!

Create reusable Global or Project Rules to ensure Warp’s agents follow your coding standards, project conventions, and personal preferences.

Warp’s Rules feature lets you create reusable guidelines that inform how agents respond to your prompts. Rules help tailor responses to match your coding standards, project conventions, and personal preferences, making agent interactions smarter and more consistent.

Warp supports two types of rules: Global Rules and Project Rules.

Global Rules apply across all projects and contexts. They’re ideal for:

  • Coding standards and best practices
  • Workspace-wide guidelines
  • Tool configurations or preferences you want applied everywhere

Warp may also suggest Global Rules based on your usage patterns to make future interactions smarter and more consistent.

Project Rules live in your codebase and apply automatically when working within that project. They’re stored in an AGENTS.md file (or WARP.md for backwards compatibility) and can be:

  • Placed in the root of your repository
  • Added in subdirectories for more targeted guidance

When you’re in a directory:

  • Warp automatically applies the AGENTS.md (or WARP.md) in the root and in the current directory.
  • If you edit files in another subdirectory, Warp makes a best-effort attempt to include that subdirectory’s rules file as well.

Example project structure:

  • Directoryproject/
    • Directoryapi/
      • AGENTS.md API-specific rules
    • Directoryui/
      • AGENTS.md UI-specific rules
    • AGENTS.md Project-wide rules

How Warp applies these Project Rules:

  • If the current directory is ui/
    • Automatically applied: project/AGENTS.md and project/ui/AGENTS.md
    • Best effort: project/api/AGENTS.md if editing files there
  • If the current directory is api/
    • Automatically applied: project/AGENTS.md and project/api/AGENTS.md
    • Best effort: project/ui/AGENTS.md if editing files there

When multiple rules apply, Warp follows this order of precedence:

  1. Rules in the current subdirectory’s project rules file
  2. Rules in the root directory’s project rules file
  3. Global Rules

This ensures the most specific, project-relevant rules take priority over broader ones.


  • From Warp Drive: Personal > Rules
  • From the Command Palette: search for “Open AI Rules”
  • From the Settings panel: Settings > Agents > Knowledge > Manage Rules
    • Here, you can manage both Global as well as Project Rules.
  • From the macOS Menu: AI > Open Rules
  • From the Slash Commands menu: /open-project-rules to open Project Rules directly in Warp’s code editor

Project Rules UI open in a Rules pane

  • From Warp Drive Rules pane: Personal > Rules > Global
    Add, edit, or delete any number of rules. Each rule can include:
    • Name (optional)
    • Description (what the rule does and when to apply it)
  • From the Slash Commands menu: /add-rule in Auto or Agent input modes to create a new Global Rule (automatically opens the Warp Drive Rules pane).
  • When in a directory, set up Project Rules with a slash command: Use /init in Auto-Detection or Agent Mode to:
    • Begin indexing your codebase or display indexing status
    • Generate an AGENTS.md file with initial context, or
    • Link an existing Rules file to AGENTS.md
      • Warp currently supports linking the following external Rules files: CLAUDE.md, .cursorrules, AGENT.md, GEMINI.md, .clinerules, .windsurfrules, .github/copilot-instructions.md

To view all Project Rules and open them in Warp, access it via the Warp Drive Rules pane: Personal > Rules > Project-based

When relevant, Agents automatically pull in applicable rules to guide their responses. Rules used in an interaction will appear in the conversation under References or marked as derived from a specific rule.

Context derived from memory

Context derived from memory

See our Privacy Page for more information on how we handle data with Rules.