title: "AI Rules for Windsurf IDE — Configuration Guide" description: "Configure AI coding rules and custom behaviors in Windsurf IDE." slug: "windsurf-rules" category: "skills" updatedAt: "2026-03-05T00:00:00.000Z" faqs:

  • q: "Does Windsurf support the same rules format as Cursor?" a: "Windsurf uses its own rules format in .windsurf/rules/ but the concept is similar to Cursor rules. Both support project-level and global configurations."

AI Skills & Rules
2026
Updated Mar 5, 20265 min read
windsurf
codeium
rules
skills

AI Rules for Windsurf IDE

Overview

Windsurf IDE by Codeium supports AI coding rules that guide Cascade (Windsurf's AI agent) to follow your project's coding conventions.

Configuration Locations

| Location | Scope | |----------|-------| | .windsurf/rules/ | Project-level rules | | Windsurf Settings → AI Rules | Global rules | | .windsurfrules | Legacy project rules |

Rule Format

# Project Architecture Rules

## Tech Stack
- Framework: Next.js 14 with App Router
- Styling: Tailwind CSS
- State: Zustand for global, React state for local
- Database: Supabase (PostgreSQL)

## Coding Conventions
- Use TypeScript strict mode
- Functional components only
- Server Components by default, 'use client' only when needed
- Error boundaries on all route segments

## File Naming
- Components: PascalCase (UserProfile.tsx)
- Utilities: camelCase (formatDate.ts)
- Routes: kebab-case (user-settings/)

Using with MCP Servers

Windsurf also supports MCP servers through .windsurf/mcp.json:

{
  "mcpServers": {
    "github": {
      "command": "npx",
      "args": ["@modelcontextprotocol/server-github"],
      "env": { "GITHUB_TOKEN": "${GITHUB_TOKEN}" }
    }
  }
}

Pair rules with MCP servers for a complete AI workflow — rules define how to code, MCP provides what tools to use.

Was this guide helpful?


Last updated: March 5, 2026