PDF download Download Article
Completely block YouTube on any browser, computer, phone, and tablet
PDF download Download Article

Do you want to prevent your child, students, or even yourself from accessing YouTube? There are many ways to block YouTube, and they're all pretty easy to do. This wikiHow article will teach you the easiest ways to block YouTube.com and the YouTube mobile app on any platform, including Windows, Mac, iPhone, iPad, and Android.

Easily Block YouTube on Windows

  1. Open the host file on your Windows computer (it might be in C:\Windows\System32\drivers).
  2. On a new line at the bottom of the document, enter 127.0.0.1, press Tab , and enter youtube.com .
  3. Add another line with 127.0.0.1, press Tab , and enter www.youtube.com .
  4. Save the edited hosts file and flush your DNS cache.
Method 1
Method 1 of 5:

Editing the "Hosts" File On Windows

PDF download Download Article
  1. The most effective way to block YouTube completely in all web browsers is to add a few lines to a text file called "hosts," which you can edit in Notepad . Because the hosts file is protected, you'll have to open Notepad in a special way to edit the file: Here's how:
    • Press Windows key + S to activate the search bar.
    • Type notepad , but don't click any search results. [1]
    • Right-click "Notepad" and select Run as administrator .
    • Click Yes to open the app.
  2. You can also get to the Open window by clicking File > Open .
    Advertisement
  3. If Windows is installed on your C drive, navigate to C:\Windows\System32\drivers\etc. If your Windows installation has a different drive letter, replace C with the correct letter. [2]
    • Don't be alarmed if the folder appears empty, as the files are hidden right now.
  4. This displays all of the files in the "\etc" folder. [3]
  5. This opens the hosts file for editing.
  6. After the last line in the file, press Enter to create a new line. Then, follow these steps:
    • Type 127.0.0.1 and press the Tab key to insert some space.
    • Type youtube.com
    • Press Enter to go to the next line.
  7. You'll do this the same way you did when blocking youtube.com :
    • On the first empty line, type 127.0.0.1 and press the Tab key to insert some space.
    • Type www.youtube.com
    • Press Enter .
  8. This is YouTube's mobile address, so you'll want to block this as well.
    • On the first empty line, type 127.0.0.1 and press the Tab key to insert some space.
    • Type m.youtube.com
  9. Now you can simply press Ctrl + S to save, or click File > Save .
  10. Until you do this, you'll still be able to access YouTube through any web browsers you've used the site in recently. The easiest way to do this is to restart your computer. If you don't want to restart right now, you can also flush your DNS cache by running a simple command: [4]
    • Press Windows key + S to activate the search bar.
    • Type cmd .
    • Right-click Command Prompt and select Run as administrator .
    • Type ipconfig /flushdns and press Enter .
  11. Advertisement
Method 2
Method 2 of 5:

Using Screen Time On a Mac

PDF download Download Article
  1. To block YouTube in all browsers on a Mac, you can restrict the site in your Screen Time settings. To get to System Settings , click the Apple menu icon in the top left corner of your screen and select System Settings . [5]
  2. You should see this in the menu on the left side of the window next to an hourglass icon on a purple background. [6]
    • If you're using Family Sharing , click the family member that you'd like to block from seeing YouTube.
  3. You'll see this in the menu on the left side of the screen. [7]
  4. This will give you more options.
  5. YouTube isn't considered an "adult website," but you'll be preventing it in the next step. [8]
  6. You'll see this under the "Web Content" selections.
  7. Doing this will let you select YouTube as a restricted site. [9]
  8. Doing this will prevent YouTube from opening in any web browser on your Mac.
  9. Advertisement
Method 3
Method 3 of 5:

Using BlockSite on Chrome & Firefox

PDF download Download Article
  1. 1
    Open the BlockSite page in the Google or Firefox web store. This is the page from which you'll install BlockSite.
    • BlockSite allows you to block individual pages or entire websites. It also allows you to set a password so that other computer users can't change your block list.
    • This only works in Google Chrome and Firefox. If you use a different web browser, you'll need to find a different blocker.
  2. 2
    Click Add to Chrome/Firefox . It's a blue button in the upper-right side of the page.
  3. 3
    Click Add extension when prompted. This option will appear at the top of the page. Clicking it prompts BlockSite to install.
  4. 4
    Click the BlockSite icon. It's a shield-shaped option in the upper-right side of the page. A drop-down menu will appear.
  5. 5
    Click. Click the gear-shaped icon in the top-right corner of the drop-down menu if you want to open the BlockSite page.
  6. 6
    Enter a website's address. Click the "Enter a web address" text box near the top of the page, then type in the address of the website that you want to block.
    • If you want to block a specific page on a website, go to that page, then copy the address by clicking the address bar at the top of the window and then pressing Ctrl + C (Windows) or CMD + C (Mac).
  7. 7
    Click + . This plus sign icon is to the right of the website text field. Your website will immediately be added to BlockSite's list of blocked websites.
    • You can remove your site from BlockSite's blacklist at any time by clicking the red circle icon to the right of the website's URL in the list of blocked sites.
  8. 8
    Click Password Protection . This tab is on the left side of the BlockSite page.
  9. 9
    Check the box next to "Require a password to access Block Site menu." Doing so will create a password text box at the bottom of the page.
    • You can also check the "Enable password access to blocked pages" box if you want your password to allow you to open blocked sites.
  10. 10
    Scroll down and enter a password. Type your preferred password (at least 5 characters) into the text box at the bottom of the page.
  11. 11
    Click Set Password . It's to the right of the password text field. This will create your password and apply it to BlockSite.
    • When accessing BlockSite in the future, you'll need to enter your password before you can add or remove sites.
    • If you forget your password to BlockSite, you can right-click the BlockSite icon and click Remove from Chrome .
  12. 12
    Allow BlockSite in Incognito mode (Chrome only). One way that people can use to get around BlockSite's restrictions is by using incognito mode, but you can enable BlockSite in incognito to fix this problem:
    • Click â‹®,
    • Select More tools,
    • Click Extensions,
    • Click DETAILS below the "BlockSite" heading,
    • Click the grey "Allow in incognito" switch.
  13. Advertisement
Method 4
Method 4 of 5:

Using Screen Time On iPhone & iPad

PDF download Download Article
  1. There are a few different ways you can block YouTube on your iPhone , but using Screen Time is the most straightforward way that blocks the YouTube app and YouTube in your iPhone's web browsers. Tap the Settings app icon, which is a grey box with gears on it. [10]
  2. It's the purple icon with an hourglass in the second group of settings. [11]
    • If Screen Time is not enabled, tap Turn on Screen Time to enable it now. Then, complete the setup process to activate Screen Time.
  3. It's at the bottom of the list. [12]
    • Enter your PIN if prompted.
  4. If the switch at the top of the menu is gray, tap it to enable the feature.
  5. It's in the first group of settings.
  6. If you want to prevent a child from opening or downloading the YouTube app (or any other apps that require the user to be of a certain age) on this iPhone or iPad, you can block the app easily: [13]
    • Tap Apps in the list.
    • Select 12+ (or younger) as the age. Since YouTube has an age suggestion of 17+, it won't be possible for your child to open the app if they're under age. The app won't even appear on their screens.
    • To undo this restriction in the future, return to this menu and select Allow all apps .
    • Tap the Back button when you're finished. You've blocked the YouTube app, but what about YouTube in a web browser? Let's fix that.
  7. It's under the "Web Content" header a bit further down the page.
  8. YouTube isn't considered an adult website, but turning this feature on allows you to add block YouTube's URL.
  9. Make sure you are tapping the option under "Never Allow," and not "Always Allow."
  10. Here's how:
    • Type youtube.com and press done }}. Now you'll see youtube.com in your "Never Allow" list.
    • Tap Add Website under "Never Allow" again.
    • Type m.youtube.com and tap done .
    • Tap Add Website again, type www.youtube.com , and then tap done .
  11. Advertisement
Method 5
Method 5 of 5:

Using Digital Wellbeing On Android

PDF download Download Article
  1. 1
    Open Settings on your Android. Using this method, you can prevent someone else or yourself from opening the YouTube mobile app. This does not block YouTube in your mobile browser, however.
    • You can open Settings by swiping down from the top of your screen and tapping the gear icon.
  2. 2
    Tap Digital Wellbeing and parental controls . It's next to an icon of a heart on a green background.
  3. 3
    Tap App timers . This will allow you to create an app timer for the mobile YouTube app.
  4. 4
    Tap Add schedule . By default, the timer is set to "00:00" Sunday - Saturday. Leave all that alone so the timer is over and applies to every day of the week.
  5. 5
    Tap Tap to select item . This opens a new window with categorized apps. For example, Spotify is listed under "Audio" and Camera is under "Image."
  6. 6
    Tap YouTube . It's under the "Video" category. When selected, the app will appear at the top of your screen under "Selected apps."
  7. 7
    Tap Done and Save . You will see an overview of the app timer you just created. However, anyone who taps the YouTube app on your phone will be able to reset this timer, so you need to continue to the next steps.
  8. 8
    Tap â‹® . You'll see this vertical three-dot menu icon in the top right corner of the screen.
  9. 9
    Tap Settings . This opens a new window.
  10. 10
    Tap the toggle next to "Set PIN" to turn it on. The switch will be colored when it's on.
  11. 11
    Create a PIN. Enter the PIN you want to use to change the timer for the YouTube app.
    • You may need to answer a security question or pick one so you can access your apps if you forget the PIN.
    • Now no one can use the YouTube mobile app on your Android without entering the PIN!
  12. Advertisement

Community Q&A

Search
Add New Question
  • Question
    How can I unblock YouTube on a single computer?
    Community Answer
    Access the admin account, select the computer's name you want to unblock, and you should see an option to unblock YouTube.
  • Question
    What software can I use to block YouTube?
    Community Answer
    You can use the application SelfControl to block specific websites, including YouTube, for a set period of time. The restrictions cannot be bypassed even if you restart your computer.
  • Question
    Why does Windows say I don't have permission when I try to save?
    Community Answer
    You need to run Notepad as an administrator. Right-click on Notepad and select "Run as administrator" before trying to save.
See more answers
Ask a Question
      Advertisement

      Video

      Tips

      • If using the iOS method, set a Screen Time Passcode in Settings so your child needs the password (which you won’t share) to click Allow.
      • You can also set a 1-minute time limit to block the iOS app.
      • There's software you can get to block websites, but many are paid. This article lists top free solutions, so your best option, if you don't like anything suggested here, might be locked behind a paywall.
      Show More Tips
      Submit a Tip
      All tip submissions are carefully reviewed before being published
      Name
      Please provide your name and last initial
      Thanks for submitting a tip for review!
      Advertisement

      Warnings

      • No blocking method will be 100% effective, especially if your child is tech-savvy. Make sure to take the time to educate your child on what is and is not allowed.
      Advertisement

      About This Article

      Thanks to all authors for creating a page that has been read 1,402,212 times.

      Is this article up to date?

      Advertisement