Clear DNS Cache on Windows & macOS

After changing your DNS settings to CleanBrowsing, you may need to clear your DNS cache so the new settings take effect immediately. This guide covers Windows, macOS, and Linux.

Windows 8, 10 & 11

  1. Press the Windows Key or click the Windows icon in the bottom left.
  2. Type Command Prompt.
  3. Right-click on Command Prompt and select Run as Administrator.
  4. In the command prompt window, type the following command and press Enter:
ipconfig /flushdns

You should see a confirmation message: "Successfully flushed the DNS Resolver Cache."

Windows 7 & Earlier

  1. Click the Start Menu.
  2. Go to All Programs > Accessories.
  3. Right-click Command Prompt and select Run as Administrator.
  4. Run the following command:
ipconfig /flushdns

macOS (Yosemite 10.10 and Later)

Open Terminal (found in Applications > Utilities > Terminal) and run:

sudo dscacheutil -flushcache
sudo killall -HUP mDNSResponder

Enter your administrator password when prompted.

macOS (Older Versions)

OS X 10.7 – 10.8 (Lion, Mountain Lion):

sudo killall -HUP mDNSResponder

OS X 10.5 – 10.6 (Leopard, Snow Leopard):

dscacheutil -flushcache

OS X 10.4 (Tiger):

lookupd -flushcache

Linux

Most distributions:

sudo /etc/init.d/nscd restart

Ubuntu:

sudo service network-manager restart
Tip: Clearing your DNS cache ensures that all new requests go to the CleanBrowsing DNS servers rather than using old cached entries.

Related Guides

Clear DNS Cache (Browser)

Clear DNS cache in Chrome, Firefox, Safari, and more.

Common Questions

Answers to frequently asked questions and fixes.

Generic Router Guide

Universal guide for configuring DNS on most routers.