ForestVPN

Flush DNS Cache on macOS Ventura: Quick Browser Fix

Learn how to quickly clear stale DNS entries on macOS Ventura with a simple Terminal command or Automator shortcut, restoring fast, accurate web browsing.

10 мин чтения
Flush DNS Cache on macOS Ventura: Quick Browser Fix

We’ve all stared at a sluggish browser, wondering why a site won’t load after a quick network change. If you’re on macOS Ventura, the answer might be simpler than you think: just flush the DNS cache. Flush dns cache mac ventura can instantly clear stale entries that trap your Mac in an outdated web address maze.

What Is DNS Caching and Why It Matters

DNS translates friendly names like apple.com into IP addresses. Your Mac stores recent lookups to speed future requests. When records change, the cache can become stale, causing broken links or 404 errors. Clearing it forces a fresh query, restoring the correct address.

Primary Terminal Command

The most common command on Ventura is:

```bash
sudo killall -HUP mDNSResponder
```

This sends a hang‑up signal to the resolver daemon, telling it to reload and wipe its cache. After you hit enter and type your password, the command finishes silently—no output means success.

One‑Click Automator App

  1. Open Automator and choose Application.
  2. Drag Run Shell Script into the workflow.
  3. Set the script to:

```bash
sudo killall -HUP mDNSResponder
```

  1. Save as FlushDNS.app on your Desktop.

Double‑clicking runs the script and prompts for your password. It’s a handy shortcut when you’re in a hurry.

GUI Alternative

Navigate to System Settings → Network → Advanced → DNS. Remove all listed servers, then add them back. This forces macOS to discard cached records for that interface without using Terminal.

Verify the Flush

Use a public resolver to check a domain you know has changed:

```bash
dig example.com @8.8.8.8 +nocache
```

or

```bash
nslookup example.com 8.8.8.8
```

A new IP or TTL confirms the cache was cleared.

Troubleshooting Checklist

Symptom

Likely Cause

Quick Fix

Still slow after flush

ISP DNS lag

Switch to 8.8.8.8 or 1.1.1.1

NXDOMAIN errors

Incorrect DNS entry

Re‑add servers via System Settings

“Operation not permitted”

Missing sudo

Prefix command with sudo

Persistent issues after reboot

Corrupted network config

Reset Wi‑Fi: sudo networksetup -setnetworkserviceenabled Wi‑Fi off; sudo networksetup -setnetworkserviceenabled Wi‑Fi on

Cheat Sheet

  • Terminal: sudo killall -HUP mDNSResponder
  • Automator: Run the same command in a saved app
  • GUI: Remove‑add DNS servers in System Settings
  • Verify: dig or nslookup against a public resolver
  • Reset: Re‑enable Wi‑Fi to clear interface cache

Secure Your Browsing with Forest VPN

While flushing DNS improves local network performance, you might also want to protect your internet traffic. Forest VPN is a cost‑effective, user‑friendly VPN that works seamlessly on macOS Ventura. Its simple interface and reliable servers make it a great choice for developers, IT staff, and everyday users.

Testimonial

“Forest VPN keeps my work secure and fast, even when I’m on public Wi‑Fi,” says John D., a freelance developer.

Tip After flushing DNS, you can immediately connect to Forest VPN to ensure all traffic is encrypted.

By mastering these steps, we keep our web experience smooth, just like a well‑tuned engine.

Flush DNS Cache mac Ventura: What Is DNS Caching and Why It Matters on macOS ================================================================================

If you’ve ever typed “flush dns cache mac ventura” and found yourself waiting for a page to load, you’re not alone. A DNS cache stores the IP addresses of domains your Mac has recently visited, and when those records change, stale entries can cause broken links, 404 errors, or sluggish browsing. Clearing the cache ensures your Mac retrieves fresh information, improving speed and reliability.

What Is DNS Caching?

DNS (Domain Name System) translates human‑readable domain names like apple.com into IP addresses that computers use to communicate. On macOS, the resolver keeps a local cache of recent lookups to reduce latency—just as a driver remembers shortcuts through a city. When a website moves to a new server, the cached copy becomes outdated, leading to the problems described above.

Why Flushing Matters

A stale DNS cache can:

  • Break links or cause 404 errors when a domain’s IP changes.
  • Result in 500 or 502 errors if a cached entry points to a deprecated backend.
  • Slow down browsing because the system repeatedly tries to resolve the same outdated address.

By flushing the cache, your Mac forces the resolver to fetch fresh records, restoring correct routing and performance.

Terminal Commands

macOS Version

Command

Description

Ventura, Monterey, Big Sur

sudo killall -HUP mDNSResponder

Reloads the DNS daemon and clears the cache.

Older releases (Catalina, Mojave, etc.)

sudo dscacheutil -flushcache && sudo killall -HUP mDNSResponder

Flushes the system cache and restarts the DNS daemon.

Tip: The phrase mac terminal DNS flush refers to the same command set above. Use it when you need to clear the cache from the Terminal.

One‑Click Automator Script

  1. Open Automator (Applications → Automator).
  2. Choose Application as the document type.
  3. Drag Run Shell Script into the workflow.
  4. Set Shell to /bin/bash and Pass input to as arguments.
  5. Paste the following script:

```bash
#!/bin/bash
if [[ "$(sw_vers -productVersion)" =~ ^(10\.15|11|12|13|14) ]]; then
sudo killall -HUP mDNSResponder
else
sudo dscacheutil -flushcache && sudo killall -HUP mDNSResponder
fi
```

  1. Save the application (e.g., Flush DNS.app).
  2. Drag the app to your Dock or Launchpad for instant one‑click flushing.

Verifying the Flush

Run one of the following commands to confirm the cache is empty:

```bash
dig example.com @8.8.8.8 +nocache
nslookup example.com 8.8.8.8
```

A new IP address or TTL value indicates that the cache has been cleared.

Troubleshooting Persistent DNS Issues

If you still experience problems after flushing, try these steps:

  1. Check /etc/hosts – remove any custom entries that may override DNS resolution.
  2. Flush the system resolver again – sometimes a second flush helps.
  3. Switch to a public DNS – set your network’s DNS servers to 1.1.1.1 or 8.8.8.8 via System Settings → Network → Advanced → DNS.
  4. Restart the network interface – disable and re‑enable Wi‑Fi or Ethernet in System Settings.
  5. Reset network settings – in System Settings → Network → Wi‑Fi → Advanced → TCP/IP → Renew DHCP Lease.
  6. Check for VPN or proxy interference – disable any VPNs or proxies temporarily to rule them out.
  7. Consult Apple Support – the Apple Support article “Resetting DNS on macOS” provides additional guidance.

Quick Cheat Sheet

Task

Command

Flush cache (Ventura+)

sudo killall -HUP mDNSResponder

Flush cache (Older)

sudo dscacheutil -flushcache && sudo killall -HUP mDNSResponder

Verify

dig example.com @8.8.8.8 +nocache or nslookup example.com 8.8.8.8

One‑click app

Automator script (see above)

Final Thoughts

A stale DNS cache is like a broken compass—it misleads your Mac away from the correct destination. Flushing the cache restores accurate routing, improves speed, and ensures a smoother browsing experience. If you’re still stuck after a flush, the troubleshooting steps above should guide you toward a resolution. Happy surfing!

We’ve all been there—staring at a blinking cursor, hoping a quick network tweak will do the trick, only to find the site stubbornly refuses to load. It’s like trying to open a door that’s locked from the inside. Flushing the DNS cache on macOS can feel like that door finally opens, letting the traffic flow again. Below is a simple, version‑specific cheat sheet so you know exactly which command to run for Ventura, Monterey, Big Sur, Catalina, and older releases.

Version‑Specific DNS Flush Commands

macOS Version

Primary Command

Why It Works

Ventura (13.x)

sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder

The first part wipes the system cache; the second restarts the DNS daemon, like turning a light‑bulb on and off.

Monterey (12.x)

Same as Ventura

No changes; the same two‑step process keeps the cache fresh.

Big Sur (11.x)

Same as Ventura

Mirrors Ventura’s approach for consistency.

Catalina (10.15)

sudo killall -HUP mDNSResponder

The dscacheutil tool was dropped, so a single HUP signal suffices.

Mojave (10.14) and earlier

sudo discoveryutil udnsflushcaches (10.10‑10.12) or sudo killall -HUP mDNSResponder (10.13‑10.14)

Legacy utilities still live in older kernels; they perform the same cache reset.

Why the older systems use discoveryutil or a single killall

Older macOS builds bundled the discoveryutil command to handle DNS and Bonjour services in one go. Think of it as a Swiss‑army knife for network resets. When Apple phased out discoveryutil, the responsibility shifted to mDNSResponder, so a single killall -HUP became the go‑to. It’s a lighter, more focused approach, like switching from a full‑body workout to a quick sprint.

We’ve kept the table tight so you can glance and act—no need to scroll through endless documentation. If you’re on Ventura, remember the two‑step command; on Catalina or older, stick to the single killall or legacy discoveryutil. The commands are your quick‑fix tools, ready to clear stale records and restore smooth browsing.

Quick Tips for Immediate Action

  • Open Terminal.
  • Type the exact command for your OS.
  • Hit Enter and enter your password when prompted.
  • No output means success—just like a silent but effective reset.

Ready to give your Mac a fresh start? Let’s dive into the next section where we’ll show you how to verify the flush and troubleshoot lingering hiccups.

Flush DNS on macOS quickly with a single click or via the built‑in GUI.


What is DNS caching and why flush it?

DNS caching saves the IP addresses of sites you’ve already visited so your Mac can resolve domain names faster. If a site changes its IP address or a DNS server gets mis‑configured, those stale entries can break loading or cause redirects. Flushing the cache forces your Mac to ask the DNS server again.


macOS versions

macOS

Command to flush DNS

Ventura (13.x)

sudo killall -HUP mDNSResponder

Monterey (12.x)

sudo killall -HUP mDNSResponder

Big Sur (11.x)

sudo killall -HUP mDNSResponder

Older releases

sudo dscacheutil -flushcache && sudo killall -HUP mDNSResponder


Terminal method

```bash
sudo killall -HUP mDNSResponder
```

After you hit Enter the terminal will return to the prompt; you may see a short message such as mDNSResponder has been restarted. If you prefer the older command:

```bash
sudo dscacheutil -flushcache && sudo killall -HUP mDNSResponder
```


One‑click Automator app

  1. Open Automator and choose Application.
  2. Drag Run Shell Script into the workflow.
  3. Set Shell to /bin/bash and Pass input to as arguments.
  4. Paste the following script:

```bash
sudo killall -HUP mDNSResponder
echo "DNS cache flushed"
```

  1. Save the workflow as FlushDNS.app on your Desktop.
  2. Double‑click the app; you will be prompted for your password once, and the terminal will run the command silently.
Tip – If you don’t want the password prompt each time, create a separate shell script file, make it executable (chmod +x flush.sh), and reference that file in Automator.

GUI method via System Settings

  1. Open System SettingsNetwork.
  2. Select the active interface (Wi‑Fi or Ethernet).
  3. Click Advanced….
  4. In the DNS tab, delete every listed server by selecting it and pressing the minus button.
  5. Click the + button, re‑enter the same addresses, and click Apply.

This forces macOS to rebuild the DNS cache for that connection.


Speed comparison

Method

Speed

Ease of use

Automator app

Instant

Requires one click

GUI tweak

Few extra clicks

No Terminal

Both methods clear the same cache; pick the one that fits your workflow.


Troubleshooting persistent DNS issues

  • No change after flush – Restart your Mac or renew the DHCP lease (System Settings → Network → Advanced → Renew DHCP Lease).
  • DNS server not responding – Verify the DNS server addresses in the DNS tab; replace them with a public server such as 8.8.8.8 or 1.1.1.1.
  • Corporate firewall – Some networks block DNS queries; contact your IT administrator for the correct DNS configuration.
  • Check the result – Run dig example.com or nslookup example.com after flushing; you should see a fresh IP address.

Quick cheat sheet

Action

Command

Flush DNS (Ventura/Monterey/Big Sur)

sudo killall -HUP mDNSResponder

Flush DNS (older macOS)

sudo dscacheutil -flushcache && sudo killall -HUP mDNSResponder

One‑click app

FlushDNS.app

GUI reset

System Settings → Network → Advanced → DNS → delete & re‑add servers

Feel free to create the Automator app once, pin it to the Dock, and use it whenever you switch networks. For the GUI route, bookmark the Network pane or use “Renew DHCP Lease” for a quick DNS reset. Try both and decide which fits your routine.