Understanding SOCKS Proxy Settings on Mac
A SOCKS proxy routes your internet traffic through an intermediary server, providing privacy and allowing access to geo-restricted content. However, there are many situations where you need to remove or disable these settings, whether you are troubleshooting connectivity issues, no longer need the proxy service, or want to restore your default network configuration.
This comprehensive guide covers all methods for removing SOCKS proxy settings on Mac, including the graphical interface approach for macOS Ventura, Sonoma, and Sequoia, Terminal commands for power users, and application-specific proxy removal.
Method 1: Remove SOCKS Proxy via System Settings (macOS Ventura, Sonoma, Sequoia)
Apple redesigned System Preferences into System Settings starting with macOS Ventura. Here is how to remove SOCKS proxy settings in the modern interface:
Step-by-Step Instructions
- Open System Settings - Click the Apple menu in the top-left corner of your screen and select System Settings. Alternatively, use Spotlight Search (Cmd + Space) and type "System Settings".
- Navigate to Network - In the left sidebar, scroll down and click on Network. You will see all your network interfaces listed.
- Select Your Active Connection - Click on the network interface you are currently using, typically Wi-Fi or Ethernet. The active connection will show a green dot or "Connected" status.
- Access Network Details - Click the Details button next to your selected network connection.
- Open Proxy Settings - In the details window, click on Proxies in the left sidebar.
- Disable SOCKS Proxy - Locate the SOCKS Proxy option in the list. If it has a checkmark, click to uncheck it. This disables the SOCKS proxy for this network.
- Save Changes - Click OK to close the details window, then close System Settings. Your changes are saved automatically.
Verifying the Change
After removing the SOCKS proxy, verify that your connection is using your direct internet connection:
- Open Safari or your preferred browser
- Visit whatismyip.com or similar IP checking service
- Confirm the displayed IP address matches your actual ISP-assigned IP
- If the proxy IP still appears, try toggling Wi-Fi off and on
Method 2: Remove SOCKS Proxy on Older macOS (System Preferences)
If you are running macOS Monterey or earlier, the interface uses System Preferences instead of System Settings:
Step-by-Step Instructions for Legacy macOS
- Open System Preferences - Click the Apple menu and select System Preferences, or use Spotlight to search for it.
- Click Network - Select the Network preference pane from the grid of icons.
- Select Your Network Interface - In the left column, click on Wi-Fi, Ethernet, or whichever connection you are using.
- Click Advanced - With your network selected, click the Advanced button in the lower right corner.
- Go to Proxies Tab - In the Advanced window, click the Proxies tab.
- Uncheck SOCKS Proxy - In the list of proxy protocols, find SOCKS Proxy and uncheck its checkbox.
- Apply Changes - Click OK to close the Advanced window, then click Apply in the main Network window.
Method 3: Remove SOCKS Proxy Using Terminal Commands
For users who prefer command-line tools or need to script proxy removal, Terminal provides powerful options for managing network settings.
Disable SOCKS Proxy via networksetup
The networksetup command allows direct manipulation of network configuration:
# View current SOCKS proxy settings for Wi-Fi
networksetup -getsocksfirewallproxy Wi-Fi
Disable SOCKS proxy for Wi-Fi
networksetup -setsocksfirewallproxystate Wi-Fi off
Disable SOCKS proxy for Ethernet
networksetup -setsocksfirewallproxystate Ethernet off
List all network services to find correct name
networksetup -listallnetworkservices
Clear Proxy Environment Variables
If you set proxy settings via environment variables in your shell, you need to remove them from your configuration files:
# Check current proxy environment variables echo $http_proxy echo $https_proxy echo $all_proxy echo $SOCKS_PROXY
Unset proxy variables for current session
unset http_proxy unset https_proxy unset all_proxy unset SOCKS_PROXY unset no_proxy
Permanently Remove Shell Proxy Configuration
Edit your shell configuration file to remove proxy settings permanently:
# For Zsh (default on modern macOS) nano ~/.zshrc
For Bash
nano ~/.bash_profile
Comment out or delete lines like:
export http_proxy="socks5://127.0.0.1:1080"
export https_proxy="socks5://127.0.0.1:1080"
export all_proxy="socks5://127.0.0.1:1080"
After editing, reload the configuration
source ~/.zshrc
Removing SOCKS Proxy from Specific Networks
macOS stores separate proxy settings for each network you connect to. If you use multiple Wi-Fi networks, you may need to remove proxy settings from each one individually.
Network-Specific Proxy Removal
| Network Type | Where to Configure | Notes |
|---|---|---|
| Home Wi-Fi | System Settings > Network > Wi-Fi > Details | Settings persist for this SSID |
| Work Wi-Fi | System Settings > Network > Wi-Fi > Details | May require admin password if managed |
| Ethernet | System Settings > Network > Ethernet > Details | Separate settings from Wi-Fi |
| VPN | System Settings > Network > VPN > Details | Some VPNs override proxy settings |
Locations Feature for Multiple Configurations
macOS supports Network Locations, allowing you to save different network configurations:
- Go to System Settings and then Network
- Click the three-dot menu and select Locations
- Create a new location without proxy settings
- Switch between locations as needed
Clearing Proxy Settings from Applications
Some applications maintain their own proxy configurations independent of system settings. Here is how to clear SOCKS proxy settings from common applications:
Safari
Safari uses system proxy settings by default. If you have removed the system proxy but Safari still uses it, try:
- Quit Safari completely (Cmd + Q)
- Clear Safari cache: Safari then Settings then Privacy then Manage Website Data then Remove All
- Relaunch Safari
Firefox
Firefox maintains independent proxy settings:
- Open Firefox and go to Settings (Cmd + Comma)
- Search for "proxy" in the settings search bar
- Click Settings next to Network Settings
- Select "No proxy" or "Use system proxy settings"
- Click OK
Chrome
Chrome typically uses system proxy settings on Mac. To verify:
- Go to Chrome Settings (chrome://settings)
- Search for "proxy"
- Click "Open your computer's proxy settings"
- This opens System Settings where you can verify proxy is disabled
Terminal Applications (curl, wget, git)
Command-line tools often respect environment variables. Even after clearing shell config, you may need to:
# Check git proxy settings git config --global --get http.proxy git config --global --get https.proxy
Remove git proxy settings
git config --global --unset http.proxy git config --global --unset https.proxy
Check curl configuration
cat ~/.curlrc
Remove any proxy lines from this file
Troubleshooting SOCKS Proxy Removal
If you have followed the steps above but your connection still routes through a proxy, try these troubleshooting steps:
Common Issues and Solutions
| Problem | Possible Cause | Solution |
|---|---|---|
| Proxy still active after disable | Network cache not refreshed | Toggle Wi-Fi off/on or restart Mac |
| Settings revert after reboot | MDM or configuration profile | Check System Settings then Privacy then Profiles |
| Cannot uncheck proxy option | Managed by organization | Contact IT administrator |
| Apps still use proxy | App-specific settings | Check individual app configurations |
| VPN overriding settings | VPN enforces proxy | Disconnect VPN or check VPN settings |
Flush DNS Cache
After removing proxy settings, flushing the DNS cache can help ensure fresh connections:
# Flush DNS cache on macOS
sudo dscacheutil -flushcache sudo killall -HUP mDNSResponder
Check for Configuration Profiles
Organizations may deploy proxy settings via configuration profiles:
- Go to System Settings then Privacy and Security
- Scroll down to Profiles (if present)
- Review any installed profiles for proxy configurations
- Remove profiles if not needed (may require admin password)
Reset Network Settings
As a last resort, you can reset network settings to defaults:
# Remove network preferences (creates backup) sudo mv /Library/Preferences/SystemConfiguration/preferences.plist /Library/Preferences/SystemConfiguration/preferences.plist.backup
Restart to regenerate default settings
sudo shutdown -r now
Warning: This removes all saved Wi-Fi networks and network configurations. Use only as a last resort.
Understanding Why SOCKS Proxy Was Enabled
Before removing the SOCKS proxy, it helps to understand why it might have been configured in the first place. Common reasons include:
Legitimate Use Cases
- Privacy Protection - SOCKS proxies hide your real IP address from websites and services you visit
- Bypassing Geo-Restrictions - Access content that is blocked in your geographic region
- Corporate Requirements - Some organizations require proxy usage for security compliance
- Development Testing - Developers often use proxies to test applications with different IP addresses
- SSH Tunneling - SOCKS proxy is commonly created via SSH dynamic port forwarding
Potential Security Concerns
If you did not intentionally set up the SOCKS proxy, its presence could indicate:
- Malware - Some malicious software routes traffic through proxy servers for surveillance
- Leftover Configuration - A VPN or security application may have left proxy settings after uninstallation
- Unauthorized Access - Someone with access to your Mac may have configured the proxy
If you suspect malware, run a full system scan with reputable security software after removing the proxy settings.
Verifying SOCKS Proxy is Completely Removed
After completing the removal process, verify that no proxy is active:
Quick Verification Steps
- Check IP Address - Visit whatismyip.com and confirm it shows your real IP, not a proxy IP
- Test Connection Speed - Proxies often add latency; run a speed test to verify normal speeds
- Check System Settings - Revisit Network then Details then Proxies to confirm SOCKS Proxy is unchecked
- Verify Environment - Run
env | grep -i proxyin Terminal to ensure no proxy variables are set
Network Utility Check
# Trace route to verify direct connection traceroute google.com
Check current network configuration
ifconfig en0
Verify no proxy in current session
echo $ALL_PROXY $all_proxy $SOCKS_PROXY
Re-Enabling SOCKS Proxy If Needed
If you only need to temporarily disable the proxy, you can easily re-enable it later. Rather than deleting the configuration entirely, simply uncheck the SOCKS Proxy option without clearing the server address and port. This allows you to quickly toggle the proxy on when needed.
For command-line users, use this command to re-enable:
# Re-enable SOCKS proxy for Wi-Fi networksetup -setsocksfirewallproxystate Wi-Fi onSummary
Removing SOCKS proxy settings on Mac is straightforward once you know where to look. The primary method is through System Settings then Network then Your Connection then Details then Proxies, where you uncheck the SOCKS Proxy option. For command-line users, networksetup -setsocksfirewallproxystate provides direct control. Remember to check application-specific settings and shell environment variables for complete removal. After making changes, verify by checking your IP address and testing your connection speed. If proxy settings keep returning, investigate configuration profiles or potential malware as the root cause.