Subdomain Blocking

I recommend adding a feature so subdomains can be blocked while leaving the higher domain free. I ask for this feature because there are websites where their ads are pulled up through a subdomain.
A prominent example of this is the site kissanime. They load their ads like "kissanime.ru/ads", and so if you could block the /ads subdomain without blocking the base domain, you would be able to cripple all of their ads while still being able to view the site.

/ads is actually a subdirectory off the web server and not a domain portion. Pi-hole only knows that you are going to the .ru domain only.

Bad example (I realized later), but it'd still be a nice feature. Such as if you're ok with someone accessing one part of a website, but not another

You should be able to exact block sub.domain.com and still be able to access domain.com.

1 Like

If you want for example block certain sub-reddits and others not, it won't work with sub.domain.com and still accessing domain.com

Is it possible to include an else/if statement in pi-hole to see if it is a sub-directory or not and block or block not depending on that? - sry no programmer at all myself ^^

Or is it, that pi-hole can't see in which sub-directory you are, since it only asks what the domain is?

In the URL https://discourse.pi-hole.net/t/subdomain-blocking/ the only information Pi-hole sees is discourse.pi-hole.net. The only thing Pi-hole can block is either discourse.pi-hole.net or pi-hole.net. You can blacklist exact discourse.pi-hole.net and still visit pi-hole.net. Pi-hole does not know anything else.