Setting up SOCKS5 on a Mac is not one action, it is three different ones that look alike: a per-service field in System Settings, a per-app field inside whatever browser or client you use, and a per-command flag in Terminal. They read from different sources, and a proxy that works in one place can be invisible in the other two.
The bigger constraint is the endpoint itself. The system field carries a server, a port and a bypass list, and that is all, so the server has to accept the no-authentication method and has to resolve the hostname the system hands it. Of 80 sockets sampled from a 79,997-socket public pool on 29 October 2026, two met both conditions.
The two survivors are not special cases. They are what a system-level SOCKS5 needs to look like, and most public endpoints fail on the second condition rather than the first.
measured
System Settings writes a proxy into one network service at a time. On a laptop that is usually Wi-Fi, but plugging in an adapter creates a second service with its own copy, and a proxy written to the first is not in force while the second is active. The service name is the label in the sidebar, not the interface name, and networksetup is case sensitive about it.
The command line is where most guides go wrong. The write form takes four arguments after the service, and the fourth is an authentication flag rather than an optional extra. Leave it out and the command is rejected for a missing argument, which is why pasted one-liners from older posts fail on current macOS. There is also a separate switch for turning the proxy on, and setting the server does not flip it.
| Task | Command | What it changes |
|---|---|---|
| List service names | networksetup -listallnetworkservices | Nothing; prints the names to use |
| Write server and port | networksetup -setsocksfirewallproxy Wi-Fi 127.0.0.1 1080 off | The service record, not its state |
| Switch it on | networksetup -setsocksfirewallproxystate Wi-Fi on | The enabled flag for that service |
| Read back the truth | scutil --proxy | Nothing; shows SOCKSEnable and SOCKSPort |
If scutil shows an HTTP proxy block but no SOCKS block, the write landed on a service that is not the active one. That single check settles most of the "it is set but nothing changed" reports before any endpoint is blamed.
The system field has no password box. Authentication exists only on the command line through that fourth argument plus a username and password, so a GUI-configured proxy is always an unauthenticated one. Any endpoint that answers the greeting by selecting the username-and-password method is therefore out of reach of System Settings, no matter how healthy it is.
The second condition is less obvious. Safari and other system frameworks hand the proxy a hostname, which the SOCKS5 protocol carries as a domain-type target instead of a packed IPv4 address. An endpoint that only accepts the IPv4 form will refuse every request a browser makes, while answering a checker that dials 1.1.1.1 without complaint. This is the reverse of the assumption most people make about broken proxies.
The sample was drawn once with a fixed seed from a public pool of 79,997 SOCKS5 sockets and probed three times each: a greeting that offers both methods, a CONNECT to example.com:80 as a domain, and a CONNECT to the same host as an IPv4 literal. The sweep took 49 seconds and every attempt was capped at four seconds to connect and six to read.
Seven of the eighty answered at all, a rate of 8.75 percent, and 73 stayed silent. Six of the seven chose the no-authentication method and one chose username and password. Only two of the six completed a domain-name CONNECT, so the share of the sample that a Mac system proxy could actually use is 2.5 percent.
| Stage | Endpoints | Of 80 |
|---|---|---|
| Sampled | 80 | 100 percent |
| Answered the greeting | 7 | 8.75 percent |
| Chose no-authentication | 6 | 7.5 percent |
| Granted a domain CONNECT | 2 | 2.5 percent |
| Granted an IPv4 CONNECT | 0 | 0 percent |
The three that chose no-authentication but never granted anything are worth naming as a separate failure: one refused the second connection outright and two accepted it and then closed without a reply. A greeting alone therefore overstates the pool by a factor of three, which is exactly the gap between "my checker says it is up" and "Safari spins".
Both grants live in 45.74.31.0/24, and four of the seven ports that answered are in that same block on three addresses, which suggests one operator running several listeners instead of four independent services. The two that granted a domain CONNECT did so in 3,385 and 9,195 milliseconds, so the slower one takes nine seconds before a byte of page content moves.
That latency matters more on macOS than the failure rate does. Nine seconds is long enough for a browser to give up and retry, and a retry against a proxy that has just spent nine seconds opening a socket usually fails. A working endpoint that answers in nine seconds behaves like a broken one from the chair.
| Endpoint | Method chosen | Domain CONNECT | IPv4 CONNECT |
|---|---|---|---|
| 45.74.31.40:15496 | No-auth | Granted, 3.4 s | Timed out |
| 45.74.31.42:16899 | No-auth | Granted, 9.2 s | No reply |
| 45.74.31.42:4975 | No-auth | No reply | No reply |
| 45.74.31.42:6947 | No-auth | No reply | No reply |
| 45.74.31.47:4566 | No-auth | No reply | No reply |
| 8.213.134.213:8083 | No-auth | No reply | Timed out |
| 157.180.24.140:11102 | Userpass | No reply | No reply |
The single userpass endpoint is the clearest illustration of the scope problem. It answered the greeting correctly, which is more than 73 other sockets managed, and it is still unusable in System Settings, because the field that would carry its credentials does not exist there.
Terminal does not read the system proxy. curl looks at --proxy and at proxy environment variables, so with the SOCKS field switched on a bare curl still goes direct. That is not a bug and it is the reason a page that loads in Safari can be followed by a command that ignores the proxy entirely.
Inside curl the scheme decides who resolves the name. socks5 makes the Mac resolve first and send an address, socks5h sends the hostname and lets the proxy resolve. Since the two endpoints that passed here refused the address form, socks5h is the spelling that reaches them, and the same logic carries to tools that borrow the convention. ssh has no such flag and needs a ProxyCommand or a jump host instead.
The rest of the checklist is short: confirm the active service with scutil, remember that a VPN or a second adapter can switch which service is active, and treat any endpoint slower than five seconds as unusable even when it grants.
A system proxy field with no password box and no health check will accept an endpoint that has been dead for hours — and macOS will not tell you.
Download RoxyBrowserProfiles keep their own proxy, cookie jar and fingerprint on macOS, so a session can stay on one exit instead of inheriting whatever the system field points at.
No. System Settings carries a server, a port and a bypass list, so the endpoint has to accept the no-authentication method. Of 80 sampled endpoints only 6 offered that method and 2 of them completed a domain-name CONNECT, which is the shape Safari and other system apps send.
Because the two tests ask different questions. A checker that connects to 1.1.1.1 sends an IPv4 literal, while Safari sends the hostname. Among the 80 sampled endpoints, 2 granted a domain-name CONNECT and none granted the IPv4 form, so an IP-based checker reports zero on endpoints the system proxy can use.
No. Command-line tools read their own variables, so curl needs --proxy socks5h://host:port or an exported ALL_PROXY, and ssh needs its own ProxyCommand. Turning the system proxy on changes nothing for a curl run in Terminal, which is why a working browser and a failing command can coexist.
The h moves name resolution to the proxy. With socks5 the Mac resolves the hostname first and sends an IPv4 literal, with socks5h the hostname travels inside the request. Since the two endpoints that passed here only accepted the hostname form, socks5h is the scheme that reaches them.