I don't want my traffic to be proxied though Tor, but I want to anonymize DNS requests. How do I use Tor as a DNS server?

3 Answers 3


Use DNSPort 53 setting in torrc and configure nameserver to


Just to add some more information to this (and to provide a source for others), an in-depth set of instructions and alternative solutions can be found in the below wiki entry.



Actually the answer of @RichardHorrocks is quite helpful, but IMHO leaves out some of the relevant parts:

  • If you want to resolve a single hostname via Tor, use tor-resolve $hostname and for reverse (PTR) lookups use tor-resolve -x $ip. (For me, that part was relevant but nowhere else in this Q&A mentioned, hence the new reply.)

    Only drawback so far: You can't specify the query type (e.g. A, NS, MX, etc.) and also IPv6-only hosts (those with only AAAA records) can't (yet) be resolved at all and cause such a message: [warn] Got SOCKS5 status response '4': host is unreachable

  • For using Tor to generally resolve all DNS requests of the local system, the anonymous answer already shows the basics and the link in the answer of @RichardHorrocks the details.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.