Last updated: March 16, 2026

To migrate Copilot chat history to Cursor AI, export the JSON conversation files from ~/Library/Application Support/Visual Studio Code/User/GlobalStorage/github.copilot-chat/, parse them into a context document, and place the result in your project root where Cursor indexes it automatically. There is no direct import path between the two tools, so the migration involves extracting, reformatting, and recreating context through Cursor’s .cursorrules and @-mention system.

Table of Contents

Why Migrate to Cursor AI

Cursor AI builds on VS Code with integrated AI capabilities that differ from Copilot’s approach. While Copilot provides inline suggestions and chat within GitHub’s ecosystem, Cursor offers a fully integrated AI assistant that understands your entire codebase. Many developers find Cursor’s contextual awareness more powerful for complex refactoring tasks and multi-file operations.

The migration involves three main areas: exporting your Copilot conversation history, transferring project-specific context, and configuring Cursor to match your workflow preferences.

Prerequisites

Before you begin, make sure you have the following ready:

Step 1: Understand What You Are Actually Migrating

Before exploring the mechanics, it helps to be clear about what “migrating Copilot history” actually means in practice. There are three distinct categories of value stored in Copilot’s history:

  1. Conversation transcripts — The raw back-and-forth text between you and the AI. These are rarely useful to replay verbatim, but they contain decisions and explanations.
  2. Project-specific context — Architecture decisions, naming conventions, and constraints that came up in conversations and shaped how the codebase evolved.
  3. Reusable prompts — Patterns you found yourself repeating, such as “generate a Jest test for this function following our existing test style.”

Only the second and third categories are worth migrating in a structured way. Conversation transcripts are useful as a reference archive, but trying to inject raw chat history into Cursor’s context window just creates noise. Focus the migration effort on extracting the durable knowledge.

Step 2: Exporting Copilot Chat History

GitHub Copilot stores chat conversations locally on your machine. The exact location depends on your operating system and Copilot version. Here’s how to locate and export your data.

Finding Copilot Data on macOS

Your Copilot history lives in application support folders. Open Terminal and navigate to the correct directory:

cd ~/Library/Application\ Support/Visual\ Studio\ Code/User/GlobalStorage/github.copilot-chat/
ls -la

You’ll find conversation files stored as JSON. Each file represents a chat session with timestamps. Copy these files to a backup location:

mkdir ~/copilot-migration
cp -r ~/Library/Application\ Support/Visual\ Studio\ Code/User/GlobalStorage/github.copilot-chat/* ~/copilot-migration/

Finding Copilot Data on Windows

Windows users can find Copilot data in a similar location:

%APPDATA%\Code\User\GlobalStorage\github.copilot-chat\

Use File Explorer to navigate there and copy the contents to your migration folder.

Exporting via GitHub API

For a more structured export, use GitHub’s API to retrieve Copilot usage data:

curl -H "Authorization: token YOUR_GITHUB_TOKEN" \
  -H "Accept: application/vnd.github+json" \
  https://api.github.com/copilot/usage

This provides usage statistics but not individual chat messages. For complete conversation history, the local files remain your primary source.

Step 3: Reading and Parsing Copilot Conversations

Copilot stores conversations as JSON files. Here’s a Node.js script to extract and format your chat history:

const fs = require('fs');
const path = require('path');

function extractConversations(sourceDir, outputFile) {
  const files = fs.readdirSync(sourceDir);
  const conversations = [];

  files.forEach(file => {
    if (file.endsWith('.json')) {
      const content = fs.readFileSync(path.join(sourceDir, file), 'utf8');
      const data = JSON.parse(content);

      if (data.messages && Array.isArray(data.messages)) {
        data.messages.forEach(msg => {
          conversations.push({
            timestamp: msg.timestamp || file,
            role: msg.role,
            content: msg.content
          });
        });
      }
    }
  });

  // Sort by timestamp
  conversations.sort((a, b) => a.timestamp.localeCompare(b.timestamp));

  fs.writeFileSync(outputFile, JSON.stringify(conversations, null, 2));
  console.log(`Exported ${conversations.length} messages to ${outputFile}`);
}

extractConversations('./copilot-migration', './cursor-import.json');

Run this script to create a portable file containing your conversation history:

node parse-copilot-history.js

Step 4: Importing Context into Cursor

Cursor handles context differently than Copilot. Instead of storing conversation history as standalone files, Cursor integrates context directly into your project workspace. Here’s how to transfer your valuable project knowledge.

Creating a Context Reference Document

Generate a document that captures important context from your Copilot conversations:

function generateContextDocument(conversations, outputPath) {
  const importantTopics = conversations
    .filter(c => c.content.length > 200) // Filter for substantial discussions
    .map(c => `# ${c.timestamp}\n\n${c.content}\n`)
    .join('\n---\n\n');

  const content = `# Project Context\n\nExtracted from Copilot conversations.\n\n${importantTopics}`;

  fs.writeFileSync(outputPath, content);
  console.log('Context document created successfully');
}

Save this as PROJECT_CONTEXT.md in your project root. Cursor automatically indexes Markdown files, making this context available to its AI.

Using Cursor’s Context Features

Cursor provides several ways to provide context:

  1. @-mentions: Type @ in the chat to reference files, folders, or documentation

  2. Ctrl+K inline editing: Select code and press Ctrl+K for AI-assisted modifications

  3. Chat context: Cursor automatically includes relevant open files in conversations

For each significant Copilot conversation, manually recreate the context in Cursor by referencing the relevant files and explaining the project-specific requirements.

Step 5: Configure Cursor for Your Workflow

After transferring history, configure Cursor to match your preferences.

Setting Up Keyboard Shortcuts

Cursor uses many VS Code shortcuts but adds AI-specific ones. Check your keybindings:

{
  "keybindings": [
    {
      "key": "cmd+shift+l",
      "command": "cursor.chat.new"
    },
    {
      "key": "cmd+shift+space",
      "command": "cursor.inlineSuggest.accept"
    }
  ]
}

Adjusting AI Parameters

Cursor’s settings allow fine-tuning AI behavior. Access settings via Cmd+, and search for “Cursor AI”:

Migrating Custom Copilot Extensions

If you use Copilot extensions or custom prompts, recreate them in Cursor. Cursor supports custom instructions through:

  1. Project rules: Create .cursorrules file in your project root

  2. Workspace instructions: Add instructions in Cursor settings under “AI Instructions”

Example .cursorrules file:

You are working on a React TypeScript project.
- Always use functional components
- Prefer hooks over class components
- Include PropTypes or TypeScript interfaces
- Follow the component structure: components/, hooks/, utils/

Copilot vs Cursor: Feature Comparison

Understanding the differences helps you know what to reconfigure after migration:

Feature GitHub Copilot Cursor AI
Inline code completion Yes Yes
Chat interface Yes (VS Code sidebar) Yes (integrated panel)
Multi-file awareness Limited Strong (Composer mode)
Codebase indexing No Yes (auto-indexed)
Custom instructions Copilot instructions file .cursorrules
Model selection GPT-4o (fixed) Claude, GPT-4o, others
GitHub integration Native Via extensions
Price $10/mo individual $20/mo Pro

The most important difference for context migration is codebase indexing. Cursor’s automatic codebase index means you do not need to manually feed file contents into every conversation — Cursor already knows your project structure. This changes how you write prompts: instead of pasting function signatures to provide context, you reference them with @filename and Cursor retrieves the content.

Best Practices for the Transition

Migrating to a new AI assistant requires adjustment. Follow these recommendations:

Start fresh but reference the past: Don’t try to import every conversation. Focus on transferring high-value context about architecture decisions and complex problem solutions.

Rebuild context gradually: As you work in Cursor, naturally rebuild context through file references and project-specific instructions.

Use version control: Commit your context documents to Git so teammates benefit from the accumulated knowledge.

Test before abandoning: Keep Copilot accessible for a week while you adjust to Cursor. Both tools can coexist during the transition.

Invest in your .cursorrules file: This is the highest-use configuration step in the migration. A well-written rules file prevents Cursor from making suggestions that contradict your project conventions, reducing the cognitive load of reviewing AI output during the adjustment period.

Step 6: Validating the Migration

After completing the migration steps, run a structured validation to confirm Cursor is providing equivalent or better assistance compared to your Copilot setup.

A practical validation checklist:

Track your time-to-first-useful-suggestion during the first week. Most developers find Cursor’s first-day performance roughly equivalent to Copilot’s, with quality improving noticeably by day 3–5 as the codebase index refines and you learn how to frame prompts for Cursor’s model selection. The transition cost is real but short-lived — typically under a week before Cursor’s codebase awareness begins paying dividends on complex tasks where Copilot’s limited context window was previously a bottleneck.

Troubleshooting

Configuration changes not taking effect

Restart the relevant service or application after making changes. Some settings require a full system reboot. Verify the configuration file path is correct and the syntax is valid.

Permission denied errors

Run the command with sudo for system-level operations, or check that your user account has the necessary permissions. On macOS, you may need to grant terminal access in System Settings > Privacy & Security.

Connection or network-related failures

Check your internet connection and firewall settings. If using a VPN, try disconnecting temporarily to isolate the issue. Verify that the target server or service is accessible from your network.

Frequently Asked Questions

How long does it take to migrate copilot chat history and context to cursor ai?

For a straightforward setup, expect 30 minutes to 2 hours depending on your familiarity with the tools involved. Complex configurations with custom requirements may take longer. Having your credentials and environment ready before starting saves significant time.

What are the most common mistakes to avoid?

The most frequent issues are skipping prerequisite steps, using outdated package versions, and not reading error messages carefully. Follow the steps in order, verify each one works before moving on, and check the official documentation if something behaves unexpectedly.

Do I need prior experience to follow this guide?

Basic familiarity with the relevant tools and command line is helpful but not strictly required. Each step is explained with context. If you get stuck, the official documentation for each tool covers fundamentals that may fill in knowledge gaps.

Can I adapt this for a different tech stack?

Yes, the underlying concepts transfer to other stacks, though the specific implementation details will differ. Look for equivalent libraries and patterns in your target stack. The architecture and workflow design remain similar even when the syntax changes.

Where can I get help if I run into issues?

Start with the official documentation for each tool mentioned. Stack Overflow and GitHub Issues are good next steps for specific error messages. Community forums and Discord servers for the relevant tools often have active members who can help with setup problems.

Built by theluckystrike — More at zovo.one