brew install dnsmasq sudo brew services start dnsmasq
Go into your System Preferences -> Network settings and add 127.0.0.1
at the top of your list of DNS servers. Make sure you have some upstream DNS servers listed underneath — when dnsmasq cannot read from the cache, this is where it will fetch the DNS records from.
$ dig google.com | grep -i time ;; Query time: 33 msec $ dig google.com | grep -i time ;; Query time: 0 msec