Skip to content

dnscrypt-proxy Setup Guide ​

This guide will help you configure dnscrypt-proxy** to use the UK DNS Privacy Project's secure public DNS resolvers, enhancing your privacy and security by encrypting DNS queries.

Prerequisites ​

  • A working dnscrypt-proxy installation.
  • Access to the system terminal.
  • Basic knowledge of editing configuration files.

Step 1: Locate and Edit the Configuration File ​

  1. Open a terminal and locate the dnscrypt-proxy configuration file, usually found at:
    sh
    /etc/dnscrypt-proxy/dnscrypt-proxy.toml
  2. Open the file in a text editor:
    sh
    sudo nano /etc/dnscrypt-proxy/dnscrypt-proxy.toml

Step 2: Enable DNS over HTTPS (DoH) or DNS over TLS (DoT) ​

For encrypted DNS, use either DoH or DoT by modifying the server_names and stamp fields.

Using DNS over HTTPS (DoH) ​

  1. Locate the [dnscrypt_servers] section and ensure dnscrypt_servers is set to false.
  2. Under [doh_servers], set doh_servers = true.
  3. Update the server_names list:
    toml
    server_names = ['uk-dns-privacy-project']
  4. Set the stamp field to:
    toml
    stamp = 'sdns://AgcAAAAAAAAAAAAacmVzb2x2ZXIuZG5zcHJpdmFjeS5vcmcudWsKL2Rucy1xdWVyeQ'

Using DNS over TLS (DoT) ​

  1. Locate the [tls_servers] section and set tls_servers = true.
  2. Update the server_names list:
    toml
    server_names = ['uk-dns-privacy-project']
  3. Set the stamp field to:
    toml
    stamp = 'sdns://AwcAAAAAAAAAAAAacmVzb2x2ZXIuZG5zcHJpdmFjeS5vcmcudWs'

Step 3: Apply Changes and Restart dnscrypt-proxy ​

  1. Save and close the configuration file.
  2. Restart the dnscrypt-proxy service to apply the changes:
    sh
    sudo systemctl restart dnscrypt-proxy
  3. Verify that dnscrypt-proxy is running correctly:
    sh
    systemctl status dnscrypt-proxy

Step 4: Test DNS Resolution ​

Visit the UK DNS Project homepage to verify that your system is using the configured DNS.

Troubleshooting ​

  • Ensure there are no syntax errors in dnscrypt-proxy.toml.
  • Restart the service if changes are not taking effect.
  • Check logs using:
    sh
    sudo journalctl -u dnscrypt-proxy --no-pager | tail -n 20

For more assistance, visit our Getting Help page.


Cookies? Nope, we don’t use them — so there’s nothing to accept!