Flushing DNS cache on macOS
    
    •
    1 min read
  
  
     
      Heads up! This post was written in 2016, so it may contain information that is no longer accurate. I keep posts like this around for historical purposes and to prevent link rot, so please keep this in mind as you're reading.
— Cory
Here's the best way to flush DNS cache on macOS:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder; say cache flushed
Notice that last part — that's why this is the best method. You get an audible "cache flushed" almost instantaneously, and the whole process becomes that much more satisfying.
Another fun variation:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder; say booyah!
Have at it. It may be silly, but it's the little things in life. Now, go flush that DNS!
Hi there! I just open sourced my creative outlet including more than 80 web components. I'm calling it Quiet UI.Visit quietui.org to check it out!
— Cory