Configure Copilot on GitHub

Before we move over to VS Code, let’s look at Copilot’s account-level settings on github.com. You will not touch most of them today, but knowing they are there means you can come back and change them once you have used Copilot for a while. We will go over three of them. One is a feature to turn on, and two are privacy settings to look at.

Open the Settings Page

Sign in to GitHub and go to github.com/settings/copilot. (Or navigate from your profile picture → SettingsCopilot in the left sidebar.)

The page has two main sections. Features lists every place Copilot shows up: in the IDE, on GitHub.com, as a CLI, as a cloud agent, and so on. Privacy has two toggles. Most of the features are already enabled. We will turn on one that is not.

Enable “Copilot can search the web”

Scroll down the Features list until you find Copilot can search the web. By default this is set to Disabled. Change it to Enabled.

With web search on, Copilot Chat can look things up in real time through Bing: library docs, release notes, recent bugs, current best practices. This matters because Copilot’s underlying models have a training cutoff. They know about the world up to some date and nothing after that. For anything recent, such as a library API that changed last month, a framework that shipped since the cutoff, or a newly reported issue, web search is how Copilot gets information from after that date.

The Privacy Section

Scroll past Features to Privacy. There are two toggles here. Neither one is wrong either way, but you should know what each one does so you can choose for yourself.

Suggestions matching public code

This setting controls whether Copilot is allowed to surface suggestions that closely match specific public code. The options are Allow or Block.

Copilot learned from a large body of public code, and sometimes its suggestions closely resemble or exactly match a specific public file. Setting this to Block filters those near-matches before they reach you. Reasons you might want that:

  • You do not want to pull code from a public repo whose license you have not vetted.
  • You do not want Copilot silently echoing a buggy or insecure snippet from somewhere you have never seen.
  • You want your code to reflect your own thinking rather than a copy of a specific file.

Blocking does not disable Copilot. You still get suggestions shaped by the patterns Copilot learned; you just do not get near-verbatim matches. Many dev teams at companies default to Block for the license reason alone. For this chapter either setting works. I would suggest Block.

Allow GitHub to use my data for AI model training

This toggle controls whether your prompts, Copilot’s outputs, and associated context from your editor are used by GitHub to train future models. The options are Enabled or Disabled.

If you leave it Enabled, you are contributing data that helps improve future models over time. If you Disable it, your data is not used for training. There is no difference in how Copilot performs for you today either way.

Disable it if you do not want your code or prompts used for training. Leave it on if you are comfortable contributing. You can change it any time.