How to block YouTube effectively

The best solution for blocking sites is to realize that it isn’t possible to do it at the technical level and has to be done at user policy level.
“you get internet on your workplace and you are not allowed to use it to stream youtube for background music and video, if we find you doing that you are fired on the spot”.
Then you don’t have to worry about site blocking anymore.

A more-or-less “maintenance free” solution is to use one of the available “filtering DNS resolvers” in your router and find one which has suitable filters for you, but remember that users todays can easily go around it by configuring their own DNS resolvers and using DoH, or by using a VPN.
So the generic “it is not allowed” policy remains required all the time.

On ROS 7.14, I choose Adlist (Adblock) from Mikrotik.

  • First, create a new GitHub project, i.e. “MyTube Blocker”


  • Then, add MyTube Blocker list to Adlist


  • Lastly, update MyTube Blocker regularly through GitHub project

When we need to access Youtube temporarily just disable “MyTube Blocker”, or create script and scheduler to disable/enable it as we need.

Capture6.JPG
Cheers,

The Adlist (and similar service like PiHole) requires DNS from our Tix/PiHole. Still the Adlist can’t block client who uses custom DNS or PVN, but who can?

https://www.imdb.com/title/tt0079470/quotes/?item=qt0471984&ref_=ext_shr_lnk

:laughing:

I implemented a very simple solution, and so far, it’s working effectively! I added static DNS records pointing to a fake IP and configured my clients to use the MikroTik IP as their DNS server. In my small network, YouTube is inaccessible on the web, iOS, and Android unless users manually change the DNS settings on their devices which can be managed with further settings if needed.

2 youtube.com 192.168.1.1 1d
3 youtube.* 192.168.1.1 1d
4 youtube.be 192.168.1.1 1d
5 www.youtube.* 192.168.1.1 1d
6 youtubei.googleapis.com 192.168.1.1 1d
7 youtube-ui.l.google.com 192.168.1.1 1d
8 www.youtube.com CNAME 1d

Doesn’t Chrome’s (and other browsers) “Secure DNS” setting (as long as it is enabled) make this useless though?

Wasting your time and our time by prolonging this thread.

check my post and tellme if it works for you
http://forum.mikrotik.com/t/block-youtube-facebook-using-layer-7-working-perfect-and-blocking-on-pc-and-phones/183372/1

You are assuming that the Mikrotk is being used for DNS, but Chrome (and other browsers) will use it’s own DNS service over https and not query DNS/53. Therefore, your solution looks like it will not work.

the usual bull~it, nothing new

If this is still unresolved, then you can visit Russia. :laughing: No need for blocking via MT, it has already been done by the ISP.