Flush the DNS cache — via Marc Abramowitz
If a website moved to a new server, or you changed DNS settings and some sites still won't load, your Mac may be holding on to old address lookups. Flushing the DNS cache makes it look them up fresh. It's a troubleshooting step, not a speed boost.
Takes effect right away
The easy way
- Run the command and enter your password. It prints nothing when it works.
- Then reload the page that wasn't working.
Command
Run in Terminal (Applications › Utilities). It uses sudo, so macOS asks for your password.
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponderNothing to undo: the cache simply refills as you browse. Apple doesn't document which of the two parts each macOS version needs, so running both is the usual advice.
Sources
- Flushing the DNS cache on macOS — by Marc Abramowitz
- Source reviewed
- 2026-11-02
- Link checked
- 2026-11-02
- Tested hands-on
- Not by Oddbyte.Me
Oddbyte.Me hasn't tried this on every macOS version, so keep the undo handy.