# Ultracite for Cursor

Cursor works best with Ultracite when you combine committed workspace settings, a dedicated Cursor rules file, and optional post-edit hooks that run after AI-driven changes land in your repo.

## Setup files for Cursor

Ultracite uses these Cursor settings, rules, and hooks files to keep editor behavior and AI output aligned with your repo standards.

### Workspace settings

This workspace settings file keeps Cursor aligned with Ultracite for format on save, auto-fixes, and TypeScript defaults.

**File:** `.vscode/settings.json`

**JSON config:**
```json
{
  "editor.defaultFormatter": "esbenp.prettier-vscode",
  "editor.formatOnPaste": true,
  "editor.formatOnSave": true,
  "emmet.showExpandedAbbreviation": "never",
  "js/ts.tsdk.path": "node_modules/typescript/lib",
  "js/ts.tsdk.promptToUseWorkspaceVersion": true,
  "[css]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[graphql]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[html]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[javascript]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[javascriptreact]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[json]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[jsonc]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[markdown]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[mdx]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[svelte]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[typescript]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[typescriptreact]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[vue]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "[yaml]": {
    "editor.defaultFormatter": "biomejs.biome"
  },
  "editor.codeActionsOnSave": {
    "source.fixAll.biome": "explicit",
    "source.organizeImports.biome": "explicit"
  }
}
```

## Why Cursor teams choose Ultracite

The AI-first code editor built on VS Code with deep AI integration for coding assistance.

Guides AI output at the source.

Cursor can use Ultracite's rule file to steer AI generations before you even reach the formatter.

Pairs rules with automatic post-edit fixes.

Optional hooks let Cursor clean up generated edits immediately after the agent writes files.

Keeps the VS Code ergonomics developers expect.

Because Cursor is VS Code-based, you still get a familiar workspace settings model alongside AI-specific files.

## Workflow tips for Cursor

Keep Ultracite present in the day-to-day Cursor workflow with a few editor-specific habits, not just a one-time setup.

1. Generate the shared `.vscode/settings.json` file so Cursor inherits the same formatter and save behavior as the rest of the repo.
2. Add `.cursor/rules/ultracite.mdc` so Cursor generates code that already matches Ultracite's expectations.
3. Enable `.cursor/hooks.json` when you want Ultracite to run after AI edits and clean up formatting or auto-fixable issues immediately.

## Cursor FAQ

Editor-specific answers for teams rolling out Ultracite in Cursor.

### Should I use both Visual Studio Code settings and Cursor rules with Ultracite?

### What do Cursor hooks add on top of the rules file?

### Can Cursor share the same committed workspace settings as Visual Studio Code?

## Trusted by top companies

And used by thousands of open source projects.

## Install in seconds. Run in milliseconds.

Install Ultracite and start shipping code faster in seconds.
