Cursor Rules Generator
Create .cursor/rules MDC files with description, globs, and alwaysApply frontmatter.
Loading tool...
What is Cursor Rules Generator?
The Cursor Rules Generator builds .cursor/rules MDC files β the modular replacement for the legacy .cursorrules file. Each rule combines YAML frontmatter (description, globs, alwaysApply) that tells Cursor when to apply it, with a Markdown body of editing instructions. Generate rules for TypeScript strictness, React patterns, Tailwind conventions, test standards, commit formats, and documentation style β then drop them straight into your repository.
Key Benefits
- Correct MDC frontmatter format every time, no YAML syntax errors.
- Per-rule files keep Cursor context small β only matching rules are loaded.
- Six curated presets give you a production-grade baseline in one click.
- Glob chips and live warnings catch duplicate filenames and conflicting options.
- 100% offline and private β rules never leave your browser.
Common Use Cases
- β’Enforcing TypeScript strict-mode conventions across a codebase.
- β’Standardizing React component and hook patterns for AI-assisted refactors.
- β’Keeping Tailwind utility usage consistent with design tokens.
- β’Making Vitest test structure predictable for generated tests.
- β’Enforcing Conventional Commits in AI-generated commit messages.
- β’Onboarding new repos: ship a .cursor/rules directory with the starter template.
How to Use the Cursor Rules Generator
- Create a rule: Click Add rule for each convention you want to enforce. Give each rule a name β it becomes the .mdc filename.
- Fill in the frontmatter: Write a one-sentence description, pick globs for the files the rule targets, or switch on alwaysApply for project-wide rules.
- Write the rule body: List your instructions as Markdown bullets, or load a preset (TypeScript, React, Tailwind, Vitest, Commits, Docs) and edit it.
- Copy into your project: Copy or download the generated file and place it in the .cursor/rules/ directory of your repository. Cursor picks it up automatically.
Key Features
- Live MDC generation with description, globs array, and alwaysApply YAML frontmatter.
- Multi-rule tabs so you can build an entire .cursor/rules directory in one page.
- Six battle-tested presets: TypeScript Strict, React, Tailwind, Vitest, Conventional Commits, Docs.
- Toggleable glob chips for common file patterns like TypeScript, tests, and Markdown.
- Smart warnings for missing names, duplicate filenames, and globs ignored under alwaysApply.
- Copy or download ready-to-use .mdc files with automatic slugified filenames.