A lightweight, native macOS menu bar app that blocks distractions for ADHD brains — hard enough that you can't casually route around it, light enough that it stays out of your way.
Built in Swift/AppKit with no dependencies. The app lives in your menu bar; start a focus session and distracting sites, URLs, and apps are blocked until you stop.
Download the latest release — no build tools needed:
- Grab
ADHD-Focus-v0.1.0.zipfrom Releases. - Unzip and drag ADHD Focus.app into
/Applications. - First launch: right-click the app → Open → Open. (The app is not notarized, so macOS Gatekeeper warns on a normal double-click.)
Works on both Apple Silicon and Intel Macs (universal binary). Requires macOS 13 (Ventura) or later.
Starting a focus session prompts for an administrator password — that's the app editing /etc/hosts (see below).
Three layers, each catching what the previous one can't:
| Layer | Config key | Mechanism |
|---|---|---|
| Hard domain blocks | hardBlockedDomains |
Writes a marked section into /etc/hosts pointing domains at 0.0.0.0. Blocks every browser and app system-wide. |
| Smart URL rules | smartBlockedURLs |
Path-level rules (e.g. block youtube.com/shorts/* but not the rest of YouTube) enforced by polling supported browsers via AppleScript and redirecting blocked tabs to a local block page. |
| App blocks | blockedAppBundleIDs |
Quits any running app whose bundle ID is listed (e.g. com.tinyspeck.slackmacgap for Slack), checked every second while focus is on. |
Only the section between these markers in /etc/hosts is ever touched:
# >>> ADHD Focus block
# <<< ADHD Focus block
Smart URL rules work in Safari, Safari Technology Preview, Chrome (incl. Beta/Canary), Brave, Arc, and Opera. Firefox gets hard domain blocks only.
Choose Open Config from the menu bar app, or edit the JSON directly at:
~/Library/Application Support/ADHD Focus/config.json
The default config:
{
"blockedAppBundleIDs" : [],
"browserPollIntervalSeconds" : 1,
"hardBlockedDomains" : [
"facebook.com",
"instagram.com",
"reddit.com",
"tiktok.com",
"twitter.com",
"x.com",
"youtube.com"
],
"smartBlockedURLs" : [
"youtube.com/shorts/*",
"reddit.com/r/all/*",
"reddit.com/r/popular/*"
]
}To find an app's bundle ID for blockedAppBundleIDs:
osascript -e 'id of app "Slack"'Config changes are read when a focus session starts, so restart the session after editing.
Requires Xcode Command Line Tools with Swift 5.9+.
cd ADHDFocus
./Scripts/build-app.shThis produces a universal (arm64 + x86_64), ad-hoc-signed bundle at ADHDFocus/dist/ADHD Focus.app.
Run the core tests:
cd ADHDFocus
swift run ADHDFocusCoreTestsMore detail in ADHDFocus/README.md.
- Unsigned/not notarized — macOS asks for approval on first open.
- Hard blocks are domain-level only;
/etc/hostscan't see URL paths. - Smart URL rules need macOS Automation permission for each browser (you'll be prompted).
- Start/stop uses an admin password prompt each time rather than an installed privileged helper.