“There was a problem communicating with the secure web proxy server (HTTPS)” (CFNetwork error 310) on Mac

The Mac is set to use an HTTPS proxy, and the proxy does not work. Every app that follows the system proxy fails.

Fix this with your agentCopies a prompt for Claude Code, Codex or any agent that can use Terminal.

My Mac has this problem: “There was a problem communicating with the secure web proxy server (HTTPS)” (CFNetwork error 310) on Mac. Read https://kilobat.app/guides/cfnetwork-error-310-problem-communicating-with-the-secure-web-proxy-server.md and work through it with me. Install the Kilobat CLI if it’s missing: brew install seifip/kilobat/kilobat. Run the guide’s Terminal and kilobat checks yourself and tell me what you find. List the steps only I can do. Ask before you change any setting.

Applies to: macOS 13 Ventura and later. The text was checked in CFNetwork on macOS 27.2.Checked: 29 October 2026

Symptoms

  • An app shows “There was a problem communicating with the secure web proxy server (HTTPS).”
  • Console shows kCFErrorDomainCFNetwork Code=310.
  • Safari shows “can’t connect to the web proxy server”.

Likely causes

  • A proxy that is down or wrong. The proxy address or port is wrong, or the proxy is off.
  • A proxy setting from an old network. The Mac keeps a work proxy.
  • A profile or app that sets the proxy. A VPN or security app can set it.

How to check

  1. Show the proxy settings that macOS uses.

    scutil --proxy
  2. Show the secure web proxy setting for Wi-Fi.

    networksetup -getsecurewebproxy Wi-Fi

How to fix it

  1. Open System Settings › Network › Wi-Fi › Details › Proxies. Turn off Secure web proxy (HTTPS) if you do not need it.

  2. If you need it, correct the address and port with your administrator.

  3. Turn off a VPN or filter app that sets the proxy.

  4. Quit and open the app again.

With Kilobat

  1. Check Wi-Fi, the router, the internet, DNS and login pages in one step.

    kilobat diagnose
  2. If one site or service fails, find the layer that stops it.

    kilobat why example.com
  3. The CLI is free. In the app, the advice from these checks is part of Kilobat Pro. See Find why one site or API won't connect.

Questions

What is 306?

306 is the same message for the web proxy (HTTP). See the HTTP proxy line in the Proxies list.

Why do many apps fail at once?

They use the same system proxy.

Sources

  • Error text in CFNetwork.framework, macOS 27.2 (Localizable.loctable)
  • curl(1) and nc(1), man page installed with macOS 27.2

Checked on 29 October 2026.