Get featured

How to set up GitHub Copilot in VS Code and run your first task

Guide · checked against the docs on

GitHub Copilot is GitHub's AI coding assistant, and VS Code has it built in. This guide covers installing VS Code, signing in to Copilot, turning off training on your data, and giving the agent a first small task. Everything here is quoted from VS Code's setup, Copilot setup and agents quickstart pages, and GitHub's Copilot docs, checked Oct 2026.

Not affiliated with or endorsed by GitHub or Microsoft. Check their current docs before relying on these details.

Our tool page: GitHub Copilot

What you need first

VS Code's Copilot page says "To use Copilot in VS Code, you need access to GitHub Copilot with your GitHub account." If you don't have a plan yet, "you'll be signed up for the Copilot Free plan and get a monthly allowance of inline suggestions and AI credits." GitHub doesn't give exact numbers for that allowance. For paid plans, see GitHub's Copilot plans page (checked Oct 2026).

System requirements, from VS Code's docs:

Requirement
Size"a small download (< 200 MB)" with "a disk footprint of < 500 MB"
Hardware"1.6 GHz or faster processor", "1 GB of RAM"
Windows"Supported versions of Windows client (64-bit)"
macOS"macOS versions with Apple security update support"
LinuxUbuntu Desktop 20.04, Debian 10, Red Hat Enterprise Linux 8, Fedora 36

The version was 1.142 when we checked (Oct 2026).

Step 1: Install VS Code

Download it from code.visualstudio.com. From the setup docs:

Step 2: Open a project

"Select File > Open Folder... Select an existing project folder." If VS Code asks whether you trust the folder, the docs say to "review the folder contents and choose whether you trust its authors. Only trust code from sources you know."

Step 3: Sign in to Copilot

VS Code has built-in AI features. The docs note that "AI features are optional. You don't need an account to use the core editor." To turn them on: "Hover over the Copilot icon in the Status Bar and select Use AI Features. Choose a sign-in method and follow the prompts."

You can also open the Command Palette (Ctrl+Shift+P, or Shift+Cmd+P on Mac) and run "GitHub Copilot: Sign in".

Step 4: Turn off training on your data

GitHub's docs say: "Starting on April 24, 2026, if you have a Copilot Free, Copilot Pro, Copilot Pro+, or Copilot Max plan, GitHub may use your interactions with GitHub features and services—including inputs, outputs, code snippets, and associated context—to train and improve AI models."

To opt out on GitHub: "click your profile picture, then click Copilot settings. Select the 'Allow GitHub to use my data for AI model training' dropdown menu and click Disabled." GitHub also says it "does not use Copilot Business or Copilot Enterprise customer data to train AI models."

VS Code also notes that telemetry for free Copilot "is currently enabled", and you can turn it off by setting telemetry.telemetryLevel to off. For more, see our guide on whether AI coding tools train on your code.

Step 5: Your first task

The quickstart notes that these "Requests ... use AI credits from your Copilot plan." Open the Chat view with Ctrl+Alt+I (Ctrl+Cmd+I on Mac) and select + to start a new chat. For permissions, pick "Manual permissions", which "Requests your approval for running tools or accessing resources."

Here is VS Code's example prompt (we haven't tried it ourselves). It builds a tiny app, so try it in a new empty folder:

Create a task list web app in a single index.html file with embedded CSS and JavaScript. Let me add, complete, and delete tasks. Save the tasks in local storage so they persist after a page reload. Use no external libraries.

"Follow the agent's progress and review each approval request before you accept it." When it's done, "Inspect each pending edit in the editor. Use Keep to acknowledge it or Undo to revert it."

To undo a whole request: hover over an earlier request and select Restore Checkpoint. The docs warn that this "doesn't reverse terminal commands, network requests, deployments, or changes to external services." Stopping a request midway doesn't undo anything either. So keep approvals on manual, and commit to Git before you start.

Step 6: Give it project instructions

"For Copilot sessions, use .github/copilot-instructions.md for project-wide guidance." You can also "enter /init in a chat session to create starter custom instructions for a project." Our Copilot custom instructions guide walks through it.

Updating, turning it off, and removing it

To update, use "Check for Updates" in VS Code. To turn off Copilot without uninstalling, use the chat.disableAIFeatures setting. The docs say this "disables and hides features like chat or inline suggestions in VS Code and disables the Copilot extensions."

To uninstall VS Code, the docs say:

To remove your settings too, the docs list these folders:

Next steps

Not affiliated with or endorsed by GitHub or Microsoft. Check their current docs before relying on these details.