I was looking for a way to block Youtube. I searched around and found some ways, such as using openDNS on router level etc. They all were cumbersome and I wanted a simple solution. So I searched more and found that parental control on mac can do that.
In mac you can open Parental Controls, and create a new account with Parental Controls enabled or turn Parental Controls on current account. You need admin access to apply Parental Controls. Once you have Parental Controls on an account, Open Parental Controls -> Account Name -> Web -> “Try to limit access to adult websites” (Click on Customize button) -> Click + in “Never allow these websites” -> Add youtube URL Click OK, and you are done.
It took me some time to figure this out and it works well. I hope it will be helpful to someone else.