How can I block a specific URL on a DD-WRT router?

Unfortunately, the impression I get (from the DD-WRT forums) is that you can only block domains under Access Restrictions in the DD-WRT setup.

I've decided instead to set up a dedicated proxy server with DansGuardian installed on it, which will allow me a fine level of control, and block any requests that don't go through the proxy on the router using iptables in OpenWrt.

Follow these steps:

  • Go to the "Access Restrictions" tab in the dd-wrt web interface
  • Enable the policy
  • Set the name (e.g. "Block Youtube")
  • Edit the list of clients to specify which machines should be blocked from accessing YouTube

    To block all machines, use the "IP Range" at the bottom to specify all IPs except the router's (typically .1) and broadcast (.255)

  • Set the days/hours you want blocked, or "Everyday" to block it all the time
  • Under "Website Blocking by URL Address", enter
  • Click "Save", and then "Apply Settings"

There's a YouTube video that shows each step if you need it.

Perhaps I'm answering too late, but I have found a way to do what you want. Instead of adding the URL you wish to block in the "URL" category, add it to the "Keyword" category. This works fine for me.