XiaTools

How to Troubleshoot an ERR_CONNECTION_REFUSED Chrome Error

By Rohit, founder of XiaTools · Updated 14 Oct 2026

The ERR_CONNECTION_REFUSED error in Google Chrome means that your browser attempted to reach a website, but the network connection was actively blocked or rejected by the destination server, your local machine, or an intermediary device. To quickly determine whether the issue is isolated to your computer or affecting everyone, you can test the destination via the Website Down Checker on XiaTools to verify if the site is offline globally or just for you.

Troubleshooting this error requires a methodical approach, starting from your local browser and expanding outward to your operating system, local network hardware, and finally the authoritative DNS records.

1. Verify the Scope of the Outage

Before changing local settings, you need to establish whether the problem is on your end or the server's end.

  • Test on another device: Try accessing the URL using a smartphone on cellular data rather than your home Wi-Fi.
  • Use online probes: Check the target domain (e.g., example.com) against external monitoring services to confirm HTTP response codes.

If the site loads fine on mobile data, the blockage is on your local network, your ISP, or your computer's configuration. If it fails everywhere, the remote server is likely down or blocking your IP address.

2. Basic Browser and Cache Troubleshooting

Sometimes Chrome holds onto stale socket pools or corrupted local cache data that triggers connection refusals.

Clear Chrome DNS Cache

Chrome maintains its own internal DNS cache separate from the operating system.

  1. Open a new tab in Chrome and navigate to chrome://net-internals/#dns.
  2. Click the Clear host cache button.
  3. Next, select Sockets from the left-hand menu and click Flush socket pools.

Disable Extensions

Browser extensions, particularly VPNs, ad-blockers, and proxy managers, frequently modify network routing and can cause connection rejections. Open an Incognito window (Ctrl+Shift+N or Cmd+Shift+N) and try loading the site. If it loads, disable your extensions one by one to find the culprit.

3. Check Local Network and DNS Settings

Corrupted operating system DNS caches or incorrect IP configurations are primary drivers of connection refusals.

Flush the System DNS Resolver Cache

Open your command-line interface with administrative privileges and execute the appropriate command for your OS:

Windows (Command Prompt / PowerShell):

ipconfig /flushdns

macOS (Terminal):

sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder

Linux (Terminal):

sudo systemd-resolve --flush-caches

Switch to Public DNS Servers

If your local ISP DNS resolver is failing to route requests correctly, temporarily switch to a public resolver like Cloudflare (1.1.1.1) or Google (8.8.8.8).

  1. Open your network adapter properties via your operating system settings.
  2. Locate IPv4 properties and set the preferred DNS server to 1.1.1.1 and alternate to 8.8.8.8.
  3. Save changes and retry loading the page.

4. Inspect Local Firewall and Security Software

Third-party antivirus suites, firewalls, and security applications often feature web-filtering or SSL/TLS inspection engines that actively refuse inbound or outbound socket requests if they flag a security risk.

  • Temporarily disable the real-time web shield or firewall in your antivirus software.
  • If you are testing an internal development site running on 192.0.2.10 or a custom port, ensure your OS firewall isn't blocking outbound traffic on that specific port.

5. Verify Server-Side Configuration (For Site Owners)

If you manage the server behind the domain, ERR_CONNECTION_REFUSED usually indicates that the web server software (Nginx, Apache, IIS) is not running, or the firewall is blocking the requested port.

Test Port Reachability

Use curl or telnet from an external machine to verify if port 80 (HTTP) or 443 (HTTPS) is open:

curl -Iv https://example.com

Expected output if the server is up and listening:

*   Trying 192.0.2.1:443...
* Connected to example.com (192.0.2.1) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully certificate verification ok
> GET / HTTP/1.1
> Host: example.com
> User-Agent: curl/7.68.0
> Accept: */*
> 
< HTTP/1.1 200 OK

If the connection immediately times out or returns Connection refused, check your server services:

Service Manager Command to Check Status Command to Start Service
Systemd (Ubuntu/Debian/RHEL) sudo systemctl status nginx sudo systemctl start nginx
Apache (RedHat/CentOS) sudo systemctl status httpd sudo systemctl start httpd
Windows IIS Get-Service W3SVC Start-Service W3SVC

Comparison of Connection Error Types

Error Code Primary Meaning Typical Cause
ERR_CONNECTION_REFUSED Target actively rejected connection Service down, wrong port, firewall block
ERR_NAME_NOT_RESOLVED DNS lookup failed Typo in URL, expired domain, bad nameservers
ERR_CONNECTION_TIMED_OUT No response received before timeout Routing loop, heavy server load, strict firewall
ERR_SSL_PROTOCOL_ERROR Handshake failure Outdated TLS version, cipher mismatch

Common Mistakes and How to Fix Them

  • Mistake: Forgetting to include the protocol (http:// vs https://).
    • Fix: Ensure you are testing with the exact schema the server expects. Typing an HTTPS address for an unconfigured local server will result in a refusal.
  • Mistake: Testing internal IP addresses (2001:db8::1) without verifying local routing tables or subnet masks.
    • Fix: Use ping or traceroute to confirm basic reachability before troubleshooting application layers.
  • Mistake: Assuming clearing browser cache fixes server-side misconfigurations.
    • Fix: Always verify server service status using command-line tools like dig and curl before tearing down local browser configurations.

Quick Troubleshooting Checklist

  1. Test the URL on a mobile device or external monitoring tool.
  2. Flush browser socket pools and DNS cache.
  3. Flush operating system DNS resolver cache.
  4. Disable VPNs, proxies, and browser extensions.
  5. Check local firewall and antivirus web shields.
  6. Verify web server daemon status and open ports (80/443).

Frequently asked questions

What is the difference between ERR_CONNECTION_REFUSED and ERR_CONNECTION_TIMED_OUT?

ERR_CONNECTION_REFUSED means the destination server actively rejected your connection request, typically because the service is offline or blocking the port. ERR_CONNECTION_TIMED_OUT means your browser sent a request, but the server failed to respond within the allotted timeframe, often due to severe network congestion or a firewall dropping packets silently.

Can a bad hosts file cause ERR_CONNECTION_REFUSED?

Yes. If your operating system's hosts file contains an outdated or incorrect IP mapping for a domain, your computer might attempt to connect to an IP address where no web server is running, resulting in a connection refusal. Check your hosts file located at /etc/hosts on Unix systems or System32/drivers/etc/hosts on Windows.

Why do I get ERR_CONNECTION_REFUSED only on localhost during development?

This usually happens because your local development server (like Node.js, Python, or Docker) is not currently running, or it is bound to a different port than the one you are typing into Chrome. Verify that your application server is actively listening on the expected port.

Does a VPN fix ERR_CONNECTION_REFUSED?

A VPN will only fix the error if your local Internet Service Provider (ISP) is actively blocking the target website's IP address. If the remote web server is down or blocking your specific credentials, a VPN will not resolve the underlying issue.

How do I check if a specific port is blocked by my firewall?

You can use command-line utilities like Telnet or Netcat to test port connectivity directly. For example, running `nc -zv example.com 443` will tell you immediately whether TCP port 443 is open and accepting connections or being dropped.

Related articles

Free tools