GitHub Copilot Could Not Connect: Fix Network, Proxy, Cert Errors

Blog / Developer tools

GitHub Copilot Could Not Connect: Fix Network, Proxy, Cert Errors

When GitHub Copilot cannot connect, Copilot itself is usually not broken. Some link between your editor and the GitHub-related domains has failed: DNS can't resolve a name, the extension isn't using your proxy, a corporate network is replacing TLS certificates, or the extension version or sign-in state is wrong. The order I recommend: write down the original error text, check the GitHub status page to rule out a server-side incident, test the domains with curl, and only then check VS Code's proxy and certificate settings.

What does the error text tell you?

Copilot's messages show up in the bottom-right notification, the status bar icon and the Output panel. The notification is often just "could not connect to server" or "temporarily unreachable"; the useful part is the low-level error in the log. In VS Code, open the Output panel (Ctrl+Shift+U / Cmd+Shift+U), pick GitHub Copilot or GitHub Copilot Chat from the dropdown at the top right, and look for error codes such as ETIMEDOUT or ENOTFOUND.

Keyword in the logMost likely causeWhere to look first
ETIMEDOUT, ECONNRESET, endless spinnerNetwork unreachable, or proxy not taking effectcurl tests, VS Code proxy settings
ENOTFOUND api.github.com or another domainDNS resolution failurenslookup / dig, DNS settings of your proxy
self signed certificate in certificate chain, unable to get local issuer certificateA corporate proxy or security software is intercepting TLSSystem certificates, http.proxyStrictSSL
407 Proxy Authentication RequiredThe proxy requires authenticationProxy credentials, http.proxyAuthorization
401, 403, or a prompt to sign in againExpired authorization, or the account has no Copilot entitlementSign in to GitHub again, check your subscription
temporarily unreachable, and colleagues see it tooPossibly a server-side incidentGitHub status page, /en/down/copilot

This table is a rule of thumb, not a strict one-to-one mapping. For example, ETIMEDOUT can also appear during a large-scale server-side outage, which is why the next step is to rule out the server side.

Step 1: Is GitHub having an incident?

If Copilot went from working to failing everywhere within a few minutes, don't touch your local config yet. Check the status first.

  1. Open the official GitHub status page, githubstatus.com, and look at the Copilot component plus base components such as API Requests and Git Operations.
  2. Open cdnping's Is Copilot down? page. It combines the official status page, a probe that runs every 5 minutes, and one-click reports from other users. If many people report "can't connect" in the same window, it's almost certainly not just you.
  3. The API status page shows GitHub status page events that cdnping syncs every 15 minutes, with 30 days of history so you can line up timestamps.

Server-side incidents are not rare. According to the official GitHub status page records synced by cdnping, GitHub had 16 incidents between 2026-09-17 and 2026-10-17: 5 critical, 1 major and 10 minor. These cover all GitHub components and not all of them involve Copilot, but they are enough to show why you should rule out the server side first. Examples include "Incident with Actions, Pull Requests and Issues" on 2026-10-12 (UTC; minor, about 474 minutes) and "CCA Automations are delayed when starting an Automation" on 2026-10-15 (UTC; minor, about 24 minutes). cdnping only started its own probing on 2026-10-17, so these numbers come from the official status page's incident records, not from a long-term cdnping measurement. For a roundup of incidents across AI services in the same period, see AI service incidents: September-October 2026.

In your troubleshooting notes, write down when you noticed the problem, whether the status page showed an incident at the time, and the incident name. Looking back later, that is far more useful than "GitHub felt flaky that day." To understand how incident severity levels work, see How to read AI status pages.

If the status page is clean and Is Copilot down? shows no cluster of reports, the problem is most likely local. Keep going.

Step 2: Test the domains Copilot uses with curl

Copilot doesn't talk to just one domain. Sign-in and authorization go through github.com and api.github.com; completion and chat requests go to several subdomains under githubcopilot.com. The authoritative list is in GitHub's official docs (search docs.github.com for "Copilot allowlist reference"). Here are a few common ones:

# Test connectivity, TLS and timing for each domain
for h in github.com api.github.com api.githubcopilot.com \
         api.individual.githubcopilot.com copilot-proxy.githubusercontent.com; do
  echo "== $h"
  curl -sS -o /dev/null --max-time 15 \
    -w "dns=%{time_namelookup}s connect=%{time_connect}s tls=%{time_appconnect}s total=%{time_total}s code=%{http_code}\n" \
    "https://$h/"
done

How to read the results:

  • You get an HTTP status code (even a 404 or 401): the network and TLS both work, so the problem is more likely the extension, proxy settings or authorization.
  • Could not resolve host: a DNS problem; jump to Step 3.
  • Connection timed out, or a very long connect time: the network is unreachable, or you need a proxy and curl isn't using one.
  • SSL certificate problem: the certificate is being replaced; jump to Step 5.

If you normally reach the internet through a proxy, test again through it and compare:

curl -sS -o /dev/null -w "%{http_code} %{time_total}s\n" \
  -x http://127.0.0.1:7890 https://api.githubcopilot.com/

(127.0.0.1:7890 is only an example port; use your own proxy address.) If it works through the proxy but not without, VS Code isn't handing requests to the proxy. See Step 4.

You can also open cdnping's IP and environment check in a browser to see your exit IP, whether traffic is split by mainland China routing, and whether your IPv4 and IPv6 exits match. On dual-stack networks, IPv6 traffic bypassing the proxy is a common reason for "I turned on the proxy and it still times out." Details are in IPv6 proxy not working.

Step 3: What to do about ENOTFOUND

ENOTFOUND means the domain name did not resolve. First check whether all GitHub domains fail to resolve:

nslookup api.github.com
nslookup api.githubcopilot.com
# Compare against a public DNS resolver
nslookup api.githubcopilot.com 1.1.1.1

If the system DNS fails but the public DNS returns results, the problem is in your local or ISP resolver. If the returned address is clearly wrong (for example a private address or 0.0.0.0), DNS may be poisoned or hijacked; see DNS poisoning vs. DNS hijacking: how to tell them apart for how to tell.

About editing hosts: the advice online to "write some IP into hosts to fix Copilot" uses IPs that stopped working long ago. GitHub's service addresses change, and hard-coding an IP creates harder-to-diagnose failures once addresses rotate. A more reliable fix is to repair DNS itself, for example by switching to a reliable resolver or configuring DoH. See the DNS over HTTPS setup guide.

Step 4: Check VS Code's proxy settings

The Copilot extension runs in VS Code's extension host process and follows VS Code's proxy configuration, not your browser's. Open settings.json (search the command palette for "Preferences: Open User Settings (JSON)") and check these entries:

{
  "http.proxy": "http://127.0.0.1:7890",
  "http.proxySupport": "override",
  "http.proxyStrictSSL": true,
  "http.noProxy": []
}

Checklist:

  • The protocol, address and port in http.proxy match what your proxy software is actually listening on. The protocol prefix must match the type of entry point your proxy software provides. Most proxy software offers an HTTP entry point, so use that first.
  • http.proxySupport is not off. When set to override, the extension's requests are forced through the proxy above.
  • http.noProxy doesn't accidentally include github.com or githubcopilot.com.
  • After changing settings, run "Developer: Reload Window"; otherwise the extension process may still use the old configuration.
  • If you launch VS Code from a terminal (code .), note that the environment variables HTTPS_PROXY and NO_PROXY are inherited too, and conflicts with the settings file can be confusing.

Other AI coding tools have the same kind of problem, and the approach carries over: Claude Code proxy settings not working goes into more detail on environment variable precedence, and Cursor users can read Cursor "Connection failed": how to troubleshoot.

Step 5: Certificate errors usually come from the corporate network

Errors like self signed certificate in certificate chain usually mean a corporate security gateway, or a packet-capture tool or antivirus on the machine, is decrypting TLS and re-issuing certificates signed by its own root certificate. curl may work because it uses the system certificate store, but the extension process may not trust the same set.

What to do:

  1. Ask your IT department for the company root certificate (usually a .crt or .pem file) and confirm it is installed in the operating system's trusted root store.
  2. For Node.js-based processes, you can add trust through the environment variable NODE_EXTRA_CA_CERTS=/path/to/company-ca.pem, then launch VS Code from that environment.
  3. Don't leave http.proxyStrictSSL set to false long term. It turns off certificate verification, so use it only to temporarily confirm whether the problem is certificates, then set it back.

If you're on a corporate network, also confirm that company policy allows Copilot at all. GitHub's official docs include a domain allowlist for enterprise network administrators that you can pass straight to yours.

Step 6: Extension version and authorization

If the network is fine and you still see "cannot connect" or "unavailable," look at the extension and the account:

  • On the Extensions page, update both GitHub Copilot and GitHub Copilot Chat to the latest versions, and make sure VS Code itself isn't very old. Newer extension versions often require a recent VS Code.
  • Click the account icon at the bottom left, sign out of your GitHub account and sign in again to re-authorize.
  • In your account settings on github.com, confirm that your Copilot subscription or organization-assigned seat is still valid. When an organization revokes a seat, the symptom can also look like "can't connect."
  • Search the command palette for "Collect Diagnostics" and run Copilot's diagnostic command. Its output includes reachability for each domain and proxy information, and you can attach it when filing a ticket.

One more note: GitHub Copilot's supported regions and terms of use are governed by GitHub's official terms. This article only covers network and configuration faults; please use the service within what the terms of service and local regulations allow.

One-page troubleshooting order

OrderActionPass criterion
1Record the original error and time from the Output panelYou have a specific error code
2Check githubstatus.com and /en/down/copilotNo related incident, no cluster of reports
3Test the five domains with curlAll return an HTTP status code
4Compare system DNS and public DNS with nslookupResults are consistent and plausible
5Check http.proxy and http.proxySupport, then Reload WindowResults with and without the proxy match expectations
6Check the certificate chainNo certificate-related errors
7Update the extension, sign in again, confirm your seatThe status bar icon returns to normal

If you've gone through all seven steps and it's still broken, submit the error text from step 1, the curl output from step 3 and the diagnostics output to GitHub Support together; they can locate the problem faster. For a more complete four-layer network troubleshooting method, see Claude Code connection timeouts and errors: how to troubleshoot. Its layered approach works for Copilot as well.

Related articles

Keep reading