How-To Guide

How to Edit Multiple Files with Cursor Composer

Use Cursor's Composer to make AI-powered edits across multiple files. Build features, refactor modules, and scaffold code.

How to Edit Multiple Files with Cursor Composer

1

Open Composer

Press Cmd+I to open Composer. This is Cursor's most powerful feature — it can create, edit, and delete multiple files in a single operation.

2

Describe what you want

Type a high-level instruction: 'add a user settings page with a form for email and password', 'refactor the auth module to use JWT', or 'create a REST API for todos'. Composer plans and executes the changes.

3

Review the multi-file diff

Composer shows a list of all files it will modify or create, with diffs for each. Click through each file to review the changes before accepting.

4

Accept or iterate

Click 'Accept All' to apply all changes, or accept/reject individual files. You can also type follow-up instructions to refine the result.

Pro tips

  • *

    Add @file references to give Composer more context about existing code it should integrate with

  • *

    For large changes, break them into smaller Composer operations for better results

  • *

    Use 'Agent mode' in Composer for complex tasks that require running commands and reading output

More Cursor guides

Explore more