dev@local: ~/project — git
dev@local~/project$git fetch
ssh: Could not resolve hostname github.com: Name or service not known
fatal: could not resolve host
Diagnostics Translation
Your computer's DNS could not find the IP address for the remote repository's domain name.
waiting for resolution...
MediumVersion Control System

Reviewed for reference consistency: April 11, 2026

Code is Safe

SECURE

Git has paused the operation to protect your code. No data has been lost or corrupted.

What To Know

This failure happens before Git can even begin repository negotiation: the hostname itself could not be translated into a reachable network address.

Where Did It Fail?

Working Tree
Your local files
add
Staging Index
Prepared changes
commit
Local Repo
Commit history
push/fetch
Remote Server
GitHub/GitLab
The error occurred during a network exchange. Your local files are untouched, but Git cannot reach the remote server.

Commands That Trigger This

$git fetch
Trying to while on an unstable Wi-Fi network
$Using a private corporate Git server URL without being connected to the VPN
Using a private corporate Git server URL without being connected to the VPN

Technical Background

01

This is strictly an OS-level networking issue, not a Git configuration problem.

02

It confirms that the error is happening before Git even attempts to speak its protocol or verify authentication.

Underlying Causes

You are disconnected from the internet
A typo in the domain part of the remote URL (e.g., `githb.com`)
Your local network or ISP is experiencing DNS resolution failures

Frequently Asked Questions

Try running `ping github.com` (or your repo domain) in the terminal. If it fails, your internet or DNS is broken, not Git.

Related Git States