HomeHow to Block Websites on Mac: A Parent’s Step-by-Step GuideWebsite Blocking & FilteringHow to Block Websites on Mac: A Parent’s Step-by-Step Guide

How to Block Websites on Mac: A Parent’s Step-by-Step Guide

Key Takeaways

  • The simplest parent-friendly method is Screen Time → Content & Privacy → Content Restrictions. It's built right into macOS, and it's locked behind a passcode.
  • You can let it auto-limit adult sites, or block specific websites by hand by dropping them into "Never Allow."
  • Safari and Chrome each handle blocking their own way — and Chrome needs a free extension to do it.
  • If you're comfortable in the Terminal, you can block a site system-wide by editing the hosts file.
  • Nothing here is permanent. Every block can be edited or removed later, as long as you've got the passcode.

You handed your kid the MacBook for a school project, and twenty minutes later they're deep in some corner of the web you'd rather they'd never found. Here's the good news: macOS already has everything you need to block websites on your Mac for free. No extra app, nothing to install.

A Mac is usually the shared family computer, not a locked-down personal phone, so blocking sites works a little differently here. macOS gives you four built-in ways to do it: Screen Time content restrictions, Safari's own settings, a Chrome extension, and the system hosts file you edit in Terminal. Each one fits a different age, a different browser, and a different comfort level with technology.

This guide walks through all four, with the exact menu steps for current macOS — plus how to undo any block later if you change your mind. You don't need to be technical to follow along. You don't need to spend a cent, either. Here's exactly how to do it, step by step.

Why block websites on your child's Mac?

Blocking websites on your child's Mac really comes down to two everyday problems. First, cutting down on accidental run-ins with content that isn't age-appropriate. Second, closing off the distraction rabbit holes that turn a 30-minute assignment into a two-hour video session. You're not trying to lock the machine in a vault. You're setting sensible guardrails on a shared family computer — and you can loosen them as your child gets older and earns more freedom.

It also helps to keep the goal realistic. Screen time is nuanced, and what your child actually does online tends to matter more than the raw number of minutes. The American Academy of Pediatrics encourages families to build a family media plan instead of chasing a single magic time limit. For a fuller look at what's reasonable by age, see our guide on how much screen time is healthy.

Method 1 — Block websites with Screen Time (the easiest way)

Screen Time is where most parents should start. It's built into macOS Catalina (10.15) and later, it's protected by a passcode only you know, and it can filter adult sites automatically or block specific ones you pick. And it works quietly in the background — no separate app to open, no subscription to keep track of. Apple's own Screen Time restrictions documentation covers the web content controls we'll use below.

Turn on Screen Time and set a passcode

First, turn Screen Time on and lock it, so your child can't just flip it back off. On current macOS this lives in System Settings — which Apple renamed from System Preferences back in macOS Ventura.

  • Open the Apple menu and choose System Settings.
  • Click Screen Time in the sidebar.
  • Turn Screen Time on if it isn't already.
  • Turn on Lock Screen Time Settings and set a four-digit Screen Time passcode.

Make this Screen Time passcode different from your Mac login password. Otherwise your child can unlock the settings by guessing the one they already know.

Auto-limit adult websites

Next, switch on the automatic adult-content filter. This blocks broad categories of explicit sites in Safari, and you don't have to name a single one of them yourself.

  • In Screen Time, click Content & Privacy.
  • Turn on Content & Privacy Restrictions.
  • Click Content Restrictions, then Web Content.
  • Choose Limit Adult Websites.

Once Limit Adult Websites is selected, macOS leans on Apple's built-in filter to block known adult sites in Safari automatically. So you've got a baseline of protection even before you add anything by hand.

Block specific ("certain") websites

To block one particular site, add it to the Never Allow list under that same setting. This is how you block certain websites on a Mac by their exact address.

  • With Limit Adult Websites selected, find the Never Allow section.
  • Click the Add button.
  • Type the exact address you want blocked, such as www.example.com.
  • Repeat for each site you want to block.

With Family Sharing, you can manage all of this remotely from your own device — so you never have to borrow your child's Mac just to add or change a blocked site.

Method 2 — Block websites in Safari on Mac

Safari doesn't keep its own separate blocklist on a Mac. It leans on Screen Time instead, which means the Never Allow list you built in Method 1 is exactly what blocks sites in Safari. Once a site is on Never Allow, Safari refuses to load it and shows a message that the content is restricted.

That's why the adult-website filter and the Never Allow list from Method 1 do double duty — they're the Safari blocking method, with nothing extra to configure inside Safari itself. If you want more control right inside the browser, Safari also supports content-blocker extensions from the Mac App Store, which can filter specific sites and ads. For the full walkthrough of every option, see our dedicated guide to how to block websites in Safari on a Mac.

Method 3 — Block websites in Chrome on Mac

Chrome doesn't use macOS Screen Time at all, so a site sitting on your Never Allow list can still open right up in Google Chrome. If your child uses Chrome, you'll need to block sites inside Chrome as well as in Screen Time.

The simplest route is a free site-blocker extension from the Chrome Web Store. Install a reputable blocker, then add the addresses you want blocked to its list.

  • Open Chrome and go to the Chrome Web Store.
  • Search for a site-blocker extension and add it to Chrome.
  • Open the extension's options and add each website you want to block.

For a more managed setup, you can also link your child's Chrome to a supervised Google Account through Family Link, which lets you approve or block sites from your phone. The full steps live in our guide to how to block websites on Chrome.

Just keep in mind: Screen Time's Never Allow list only reliably enforces in Safari. So blocking in Chrome is a separate, necessary step any time Chrome is your child's main browser.

Method 4 — Block a website using the hosts file (Terminal)

The hosts file method blocks a website system-wide — in every browser at once — by pointing its address to a dead end on your own Mac. The address 127.0.0.1 is your Mac itself, so any request for the blocked site just loops back home and never reaches the real page. It's the most technical option here, so it suits confident users, but the steps themselves are short.

  • Open the Terminal app (Applications > Utilities > Terminal).
  • Type sudo nano /etc/hosts and press Return, then enter your admin password.
  • On a new line, add 127.0.0.1 www.example.com, replacing the address with the site you want to block.
  • Press Control-O then Return to save, and Control-X to exit.
  • Type sudo dscacheutil -flushcache and press Return to refresh the cache.

Two honest caveats about the hosts file. It works site by site, so you have to add each address manually — and a tech-savvy child who knows their way around Terminal can undo it. Treat the hosts file as a backstop for one stubborn site, not a whole-web filter.

How to unblock or edit a blocked website

Every method here is reversible, so you can loosen a block the moment it stops making sense. Reverse each one right where you first set it up:

  • Screen Time and Safari: return to Content Restrictions > Web Content, select a site under Never Allow, and click Remove; to switch off filtering entirely, set Web Content back to Unrestricted Access.
  • Chrome: open your blocker extension's options and delete the site from its list, or remove the extension.
  • Hosts file (Terminal): run sudo nano /etc/hosts again, delete the line you added, save, and flush the cache.

And because each change needs your Screen Time passcode or admin password, your child can't quietly reverse the Screen Time blocks on their own.

Blocking websites on one Mac vs. every device

Blocking a site on one Mac only covers that one Mac. Kids move between a laptop, a phone, a tablet — and a site blocked on the MacBook is still wide open on an iPhone unless you set it up there too.

To keep protection consistent, repeat the equivalent steps on every device your child uses. Screen Time settings can sync across a child's Apple devices through Family Sharing, but Chrome and Android phones each need their own setup. Our companion guide covers how to block websites on your child's iPhone using the same Screen Time approach.

Frequently Asked Questions

How do I block a website on my Mac?

The quickest way to block a website on your Mac is with Screen Time. Open System Settings > Screen Time > Content & Privacy > Content Restrictions > Web Content, choose Limit Adult Websites, then add the exact URL under Never Allow. It's free, it's built in, and it's protected by your Screen Time passcode.

How do I block a website on Safari on Mac?

To block a website in Safari on a Mac, you use Screen Time — Safari relies on it rather than keeping its own blocklist. Add the site to the Never Allow list under Content Restrictions > Web Content, and Safari will refuse to load it. See our Safari guide for the full walkthrough.

How do I block a website on Chrome on Mac?

To block a website in Chrome on a Mac, use a free site-blocker extension from the Chrome Web Store, or a supervised account through Family Link, since Chrome ignores macOS Screen Time. Install the blocker, then add each site's address to its list. A Screen Time block on its own won't stop Chrome.

How do I block certain websites on Mac?

To block certain websites on a Mac, add their exact addresses to the Never Allow list in Screen Time. Go to Content & Privacy > Content Restrictions > Web Content, keep Limit Adult Websites selected, and click Add to enter each URL. This blocks only the specific sites you list, not whole categories.

Can I block websites on Mac using Terminal?

Yes — you can block websites on a Mac using Terminal by editing the system hosts file. Run sudo nano /etc/hosts, add a line reading 127.0.0.1 followed by the site's address, save, and flush the cache with sudo dscacheutil -flushcache. It's an advanced method, and it's fully reversible.