skip to Main Content

Sometimes, you need to flush the DNS cache on OSX/Mac. This can be for any number of reasons, but usually, this is done when you have either updated DNS settings at your domain registrar or when you have updated a page on your website and need to see the updated version in your web browser.

Thankfully, OSX/Mac makes it easy to flush your DNS cache with a few simple commands.

 

1. Flush DNS Cache on OSX/Mac

First thing’s first, you need to open up a Terminal window. You can do this a couple of ways.

 

The long way:

Applications > Utilities > Terminal

Or by using the shortcut shortcut:

Command + Space > type in “terminal” (without the quotes)

 

OS X Yosemite

Type in the following to reset the DNS cache in OS X Yosemite v10.10.4:

sudo killall -HUP mDNSResponder

Type in the following to reset the DNS cache in OS X Yosemite v10.10 through v10.10.3:

sudo discoveryutil mdnsflushcache

 

OS X Mavericks 10.9, Mountain Lion 10.8, and Lion 10.7

Type in the following to reset the DNS cache:

sudo killall -HUP mDNSResponder

 

Mac OS X Snow Leopard v10.6

Type in the following to reset the DNS cache:

sudo dscacheutil -flushcache

 

I hope this helps if you’re having trouble figuring out the different variations of how to flush the DNS cache on OSX/Mac.

We also have an article on How to Flush the DNS Cache on Windows for anyone who’s interesed.

Sponsored Links

Don't be shy, leave a reply!