You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ConnectionRefused: Unable to connect. Is the computer able to access the url? #54056
Thanks for the report and for attaching the debug logs! They show OpenCode Desktop 2.0.26 on Windows, with the opencode-go provider (mostly deepseek-v4.1-flash). Sessions there fail with:
AI.Error.Transport: ConnectionRefused: Unable to connect. Is the computer able to access the url?
The same logs also show requests to https://models.opencode.ai/api.json failing with self signed certificate, and the app's update check failing with ERR_CONNECTION_RESET. That usually means something on the network is intercepting or blocking HTTPS traffic, such as a corporate proxy, a VPN, or antivirus/firewall software that inspects HTTPS.
To look into this further, could you tell us briefly, in your own words:
What you were doing when it happened (e.g. sending a prompt in a new session) and whether it ever worked on this machine or network.
Whether you're behind a proxy, VPN or company network, or running security software that inspects HTTPS. If so, have you set HTTPS_PROXY and/or NODE_EXTRA_CA_CERTS? Both are covered in the network docs.
Whether https://opencode.ai opens normally in a browser on the same machine, and whether curl -v https://models.opencode.ai/api.json reports a certificate problem.
You can reply here or edit the issue. If you edit it, please also leave a comment saying you've updated it so we know you're done.
These related issues might also help. They're ordered from most to least likely to be relevant:
opencode-debug-20261009T073523.zip
I didn't modify anything. It worked properly for a while just now, but now it's malfunctioning again. I don't think this is a network configuration issue.
Thanks for the second set of logs, that helps! You're right that you didn't change anything in OpenCode, and "works for a while, then breaks" matches what the logs show. But the logs point to something between your machine and the internet, not to an OpenCode bug. Here's what the new logs contain (times in UTC):
Sessions failed again with ConnectionRefused: Unable to connect at 07:10:42 and 07:11:27.
From about 05:28 to 07:28, requests to models.opencode.ai timed out about every 5 minutes. At 07:27:48 the hostname didn't resolve at all: getaddrinfo ENOTFOUND models.opencode.ai. Your first zip also had self signed certificate errors for the same host.
At 07:24:56 your Context7 MCP server failed with the same ConnectionRefused error. Context7 is a third-party service, not OpenCode's model provider, so connections to unrelated hosts were failing at the same time.
OpenCode only makes normal HTTPS requests. Name lookups (DNS), certificates and refused connections are handled by Windows or by software sitting in the path, such as a proxy/VPN client, a company network, or antivirus/firewall software that scans HTTPS. Failures that come and go across several unrelated hosts usually come from one of those.
To help narrow it down, could you tell us:
Do you run a proxy or VPN client (for example Clash, v2rayN or a company VPN), or antivirus or security software that inspects HTTPS? If so, does the problem go away when you turn it off, or when you set HTTPS_PROXY / NODE_EXTRA_CA_CERTS as described in the network docs?
When it fails again, what do nslookup models.opencode.ai and curl -v https://opencode.ai show in a terminal on the same machine?
If both of those work while OpenCode is failing at the same moment, please reply here with the output. That would point back to OpenCode, and we'll look into it further.
Closing this for now because we didn't get the details needed to look into it further. Thanks for sending both debug zips. They show the ConnectionRefused errors happening at the same time as other connection failures: DNS lookups failing (ENOTFOUND models.opencode.ai), timeouts, self signed certificate errors, and failed connections to the separate Context7 MCP server. That points to something between your machine and the internet, such as a proxy/VPN client, unstable DNS, or antivirus that scans HTTPS, rather than to OpenCode itself.
If it happens again, you can comment here or open a new issue. Please include:
whether you use a proxy, VPN or HTTPS-scanning security software
the output of nslookup models.opencode.ai and curl -v https://opencode.ai, run while OpenCode is failing
If those commands work at the same moment OpenCode fails, that's a strong sign of an OpenCode bug and we'll be glad to look again. The network docs cover HTTPS_PROXY and NODE_EXTRA_CA_CERTS, which might help in the meantime.
Activity
opencode-agent commentedon Oct 9, 2026
Thanks for the report and for attaching the debug logs! They show OpenCode Desktop 2.0.26 on Windows, with the
opencode-goprovider (mostlydeepseek-v4.1-flash). Sessions there fail with:The same logs also show requests to
https://models.opencode.ai/api.jsonfailing withself signed certificate, and the app's update check failing withERR_CONNECTION_RESET. That usually means something on the network is intercepting or blocking HTTPS traffic, such as a corporate proxy, a VPN, or antivirus/firewall software that inspects HTTPS.To look into this further, could you tell us briefly, in your own words:
HTTPS_PROXYand/orNODE_EXTRA_CA_CERTS? Both are covered in the network docs.https://opencode.aiopens normally in a browser on the same machine, and whethercurl -v https://models.opencode.ai/api.jsonreports a certificate problem.You can reply here or edit the issue. If you edit it, please also leave a comment saying you've updated it so we know you're done.
These related issues might also help. They're ordered from most to least likely to be relevant:
opencode-gofailing on all models with socket and certificate verification errorsopencode-gosuddenly unreachable on Windows with connection errors (reported on v1)opencode-gostreams hanging or aborting with connection errorsNecorChen commentedon Oct 9, 2026
opencode-debug-20261009T073523.zip
I didn't modify anything. It worked properly for a while just now, but now it's malfunctioning again. I don't think this is a network configuration issue.
opencode-agent commentedon Oct 9, 2026
Thanks for the second set of logs, that helps! You're right that you didn't change anything in OpenCode, and "works for a while, then breaks" matches what the logs show. But the logs point to something between your machine and the internet, not to an OpenCode bug. Here's what the new logs contain (times in UTC):
ConnectionRefused: Unable to connectat 07:10:42 and 07:11:27.models.opencode.aitimed out about every 5 minutes. At 07:27:48 the hostname didn't resolve at all:getaddrinfo ENOTFOUND models.opencode.ai. Your first zip also hadself signed certificateerrors for the same host.ConnectionRefusederror. Context7 is a third-party service, not OpenCode's model provider, so connections to unrelated hosts were failing at the same time.OpenCode only makes normal HTTPS requests. Name lookups (DNS), certificates and refused connections are handled by Windows or by software sitting in the path, such as a proxy/VPN client, a company network, or antivirus/firewall software that scans HTTPS. Failures that come and go across several unrelated hosts usually come from one of those.
To help narrow it down, could you tell us:
HTTPS_PROXY/NODE_EXTRA_CA_CERTSas described in the network docs?nslookup models.opencode.aiandcurl -v https://opencode.aishow in a terminal on the same machine?If both of those work while OpenCode is failing at the same moment, please reply here with the output. That would point back to OpenCode, and we'll look into it further.
opencode-agent commentedon Oct 12, 2026
Closing this for now because we didn't get the details needed to look into it further. Thanks for sending both debug zips. They show the
ConnectionRefusederrors happening at the same time as other connection failures: DNS lookups failing (ENOTFOUND models.opencode.ai), timeouts,self signed certificateerrors, and failed connections to the separate Context7 MCP server. That points to something between your machine and the internet, such as a proxy/VPN client, unstable DNS, or antivirus that scans HTTPS, rather than to OpenCode itself.If it happens again, you can comment here or open a new issue. Please include:
nslookup models.opencode.aiandcurl -v https://opencode.ai, run while OpenCode is failingIf those commands work at the same moment OpenCode fails, that's a strong sign of an OpenCode bug and we'll be glad to look again. The network docs cover
HTTPS_PROXYandNODE_EXTRA_CA_CERTS, which might help in the meantime.