SelfControlApp / selfcontrol

:skull: Mac app to block your own access to distracting websites etc for a predetermined period of time. It can not be undone by the app or by a restart – you must wait for the timer to run out.
http://selfcontrolapp.com
GNU General Public License v3.0
3.99k stars 399 forks source link

Does not block youtube with ad blocker enabled #540

Open smrk007 opened 5 years ago

smrk007 commented 5 years ago

I was having issues blocking youtube, and so tried turning off my ad blocker (Adblock Plus), after which blocking youtube was successful. Once I reenable Adblocker Plus, youtube is not blocked. However, this is not the same with other sites – all other sites I have tried work regardless of my ad blocker being enabled.

mandarvaze commented 5 years ago

I too noticed this. Although I did not realize it was due to Adblocker. I too have Adblocker Ultimate. Disabling it does not seem to have any effect. i.e Youtube still loads 😢

Edit : When I tried to open it in Safari, I got "Can not connect to server" error (Which I assume is from SelfControl App) Similar result with Chrome as well (i.e. it is blocked as expected) I also tried to open youtube in "New Private Window" - youtube was blocked. But in "normal" new firefox window can not block youtube.

I'm unsure whether it is related with Adblock though - cause enabling on disabling it had no effect.

Ramarti commented 5 years ago

Hi, I noticed too youtube is not blocking, but I managed to do it manually adding the following lines in /etc/hosts

200:2:253d:369e::   youtube.com
200:2:253d:369e::   www.youtube.com

Maybe youtube needs a special case? It would be cool to have it in Self Control

pentallelogram commented 4 years ago

I fixed this issue for me in firefox by disabling DNS over HTTPS:

  1. Firefox > Preferences > Network Settings > uncheck Enable DNS over HTTPS
  2. Restart Firefox

This may be relevant for other browsers as well, just search "DNS over HTTPS" in settings. Keep in mind that DNS over HTTPS is a feature that helps protect your privacy but it does so by bypassing the host system DNS, therefore breaking SelfControl.

https://support.mozilla.org/en-US/kb/firefox-dns-over-https