git
network
ai_generated
true
fatal: unable to access 'https://github.com/user/repo.git/': Could not resolve host: github.com
ID: git/unable-to-access-https
88%Fix Rate
90%Confidence
50Evidence
2023-01-01First Seen
Version Compatibility
| Version | Status | Introduced | Deprecated | Notes |
|---|---|---|---|---|
| 2 | active | — | — | — |
Root Cause
Git cannot reach the remote HTTPS endpoint. Common causes include DNS resolution failures, proxy misconfiguration, SSL certificate issues, or corporate firewall blocking.
genericWorkarounds
-
85% success Diagnose and fix the network issue (DNS, proxy, firewall)
Test connectivity with curl -v https://github.com. Check proxy settings with git config --global --get http.proxy. If behind a corporate proxy, set git config --global http.proxy http://proxy:port.
-
88% success Update SSL certificates if the error is SSL-related
Run update-ca-certificates (Debian/Ubuntu) or point git to the correct CA bundle: git config --global http.sslCAInfo /path/to/ca-bundle.crt
Dead Ends
Common approaches that don't work:
-
Disabling SSL verification globally with git config --global http.sslVerify false
70% fail
This opens the connection to man-in-the-middle attacks and does not fix DNS or connectivity issues. It only helps with certificate verification failures.
-
Switching to SSH without having SSH keys configured
80% fail
SSH requires key pairs to be generated, added to the agent, and registered with the remote host; switching without setup leads to permission-denied-publickey
Error Chain
Preceded by:
Frequently confused with: