I will be honest up front: I am not a hardware person. But I know a beautiful piece of thrift when I see one, and this is one — a whole-home ad blocker that runs on a chip costing about as much as a coffee.

The project is ESP32_AdBlocker by s60sc on GitHub:
https://github.com/s60sc/ESP32_adblocker

It has been around since 2021, is still maintained (version 3.7, 530+ stars), and it turns an ESP32 development board into a DNS sinkhole — the same trick a Pi-hole does, on a board a fraction of the size and price.

How it works

Every device in your home asks a DNS server "where is this domain?" before loading anything. Point that question at the ESP32 instead:

  • If the domain is on the blocklist (ads, trackers), the ESP32 answers 0.0.0.0 — nowhere. The ad never loads.
  • If it is a normal domain, the query is forwarded to a real DNS server and everything works as usual.

A blocklist lookup takes under 50 microseconds on an ESP32-S3. The board downloads its blocklist automatically (the well-known StevenBlack hosts file works), refreshes it daily at a set time, and gives you a web dashboard showing how many domains were allowed and how many were blocked, with controls to add or remove domains of your own. Firmware updates are OTA — no re-flashing cables after the first install.

Setup, in outline: flash the Arduino sketch to a board with PSRAM (an ESP32-S3 with 8MB PSRAM is the comfortable choice; a 4MB board may truncate a large blocklist), it boots into AP mode so you can hand it your Wi-Fi details from a web page, then you set its static IP as the DNS server in your router. Every phone, TV and laptop on the network is covered at once. Two gotchas from the README: it is IPv4-only, so disable IPv6 DNS, and turn off "secure DNS" in browsers, since that bypasses your local DNS entirely.

And the honest limit, so nobody is disappointed: DNS blocking kills third-party ad and tracker domains, but it cannot remove ads served from the same domain as the content — YouTube's own in-app ads are the classic example. What it does remove is an enormous amount of the tracking and junk traffic chattering away on a modern home network, for hardware that costs a few dollars and sips power.

That is the part I love. A Raspberry Pi setup is a small computer. This is a component — a chip you flash once, plug into any USB port, and forget. For friends who are comfortable with hardware and like controlling things at that level, it is a weekend project with a permanent payoff.

Ten-odd yuan of silicon, standing guard over the whole house.

— Terry, Airgrix