When I add that regex and query tiktok.com
I also get no results. When I try it in regex101.com
I do get a match. I think this is down to the kind of regex which Pi-hole implements.
These regexes seem needlessly complex. Is your intention to block any domain which contains the string tiktok
? If so, the simple regex blacklist
tiktok
will do that. And similarly for the other one, the regex blacklist
pubg
Please add the tiktok regex and run the test again. That will confirm that regex blocking is working. You can then remove all the complex \W*...
rules and replace with simpler rules for each word. You can combine strings too (using (string1|string2|string3)
and so on), but it's more manageable to treat each one separately – makes updating and editing much easier that way.
You may need to be a little more specific with some specific words if there is a risk of a desired domain including that string, as that would also be blocked.
If your intention is to do something other than block all domains containing these strings, please detail exactly what you want the rule to do and I'm sure we can help with a more suitable one that works.