How to flush the DNS cache on Mac OS X

Here’s how to flush (or reset) the DNS cache on Mac OS:

Mac OS X 10.7, 10.8 & 10.9

Open up a Terminal window and enter the following command to reset the DNS cache:

Mac OS X 10.6

Open up a Terminal window and enter the following command to reset the DNS cache: