Kicka

MacOS public Wi-Fi login fix

macoswifi
Source

I’ve come across numerous discussions about connecting to public Wi-Fi networks on macOS, particularly those that require login or confirmation before access (which is common in places like coffee shops, airports, and hotels). I have personally faced this issue, and after much frustration, I found a solution that has consistently worked for me.

Solution

Open Terminal and run the following command:

open -a "Captive Network Assistant"

Or, if you’re unfamiliar with using Terminal, you can access Captive Network Assistant via Finder:

  1. In Finder, press Shift + Command + G on your keyboard.
  2. Paste: /System/Library/CoreServices/Captive Network Assistant.app/Contents/MacOS
  3. Double-click Captive Network Assistant. If it doesn’t open, right-click the app, choose Show Package Contents, then open Contents → MacOS and double-click the binary file.

Why This Works

Captive portals depend on macOS detecting “limited internet” and auto-launching Captive Network Assistant. The Terminal command triggers that helper on demand, bypassing DNS/VPN/redirect quirks that prevent the automatic check from firing.

Alternative Solutions

If the portal still doesn’t appear after launching Captive Network Assistant, try one of these other methods.

Safari

  1. Go to captive.apple.com

Manually Retrieve the Captive Portal URL

  • Open Terminal and run:
  curl -I http://captive.apple.com
  • Copy the Location URL and open it in Safari.

Remove Custom DNS

  1. System Settings → Wi-Fi → Details (for the network) → DNS
  2. Delete custom servers.

Flush DNS Cache

  1. Open Terminal and run:
   sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder

Temporarily Disable Private Wi-Fi Address

  1. System Settings → Wi-Fi → Details
  2. Set Private Wi-Fi Address to Off.

Forget and Rejoin the Network

  1. System Settings → Wi-Fi → Details
  2. Forget This Network
  3. Reconnect.

Restart Wi-Fi

  1. Turn Wi-Fi off and on again (and, if needed, reboot your router).