[FEATURE] Support `url` field in `launch.json` for preview feature
Status Fixed / completed
Maintainer reply None cached
Workaround ✓ Mentioned in thread ↓
Activity 15 comments · opened Feb 27, 2026 · closed Aug 17, 2026
Preflight Checklist
- [x] I have searched existing requests and this feature hasn't been requested yet
- [x] This is a single feature request (not multiple features)
Problem Statement
My dev server runs on https and needs to be accessed via a specific URL. This seems to be incompatible with Claude code's "preview" feature which always connects to localhost
Proposed Solution
Support url in the launch.json configuration that the preview feature reads.
Alternative Solutions
_No response_
Priority
Critical - Blocking my work
Feature Category
CLI commands and flags
Use Case Example
_No response_
Additional Context
_No response_
Showing cached comments. Read the full discussion on GitHub ↗
14 Comments
+1 on this one
Another use case for this is subdomains. We rely on
http://foobar.localhost, which currently isn't possible.+1 on this one
With the advent of portless, this feature is becoming more important.
+1 this is preventing me from switching from Cursor to Claude Code
totally important, +1 on the advent of portless
+1 Unable to develop a Symfony project without it.
For the love of God add this feature +1
this would be very useful - especially for apps that require https even in development
Need! Thank you
+1 for this. A
urlfield would cover the common case where the preview server is already running (managed by a hook, launchd, or any external process) andpreview_startjust needs to open the pane against it — no process config, no path resolution needed.Same need here — our Angular app uses Keycloak for SSO, so the very first load redirects to an external auth server (
auth.ie.test.gelato.tech) before the app renders. Preview blocks it immediately with:A
urlfield inlaunch.json(or an external URL allowlist in settings) would solve this. Being able to tell Preview "trust these domains as part of the local dev flow" is the missing piece for any app with an external identity provider.Related: #27263
Adding a workaround that's been working well for HTML→Vue and Vue→HTML prototype-to-product fidelity smoke testing in our internal Claude Code workflow — sharing in case it helps others hitting the same cross-origin gap.
A path-routing reverse proxy on a single port lets the preview tool bind to one origin while reaching multiple dev servers.
preview_evalandpreview_inspectthen work across both apps because they're same-origin.Minimal zero-dependency Node implementation:
.claude/launch.jsonentry:Usage:
preview_start "smoke-proxy ...". Navigate/proto/*for the static app and/(or any path) for the dynamic app. Cross-sidewindow.location.href = '/proto/...'works;preview_evalandpreview_inspectsee both sides through the unified origin.Caveats:
<iframe>wrappers also work for screenshots-only, but Chromium blocks cross-origin DOM access forpreview_inspectinto the iframeNot a substitute for the official
url/allowedOriginsfield this issue requests — that would be the cleaner long-term solution.Running into the same thing. We use subdomains, and I'm looking to switch from Conductor due to the upcoming June 15 billing change Anthropic is imposing. Very disappointed to learn that the Claude Code preview doesn't work for subdomains.
We use 2 local loopback subdomains of our own, so need to be able to allowlist these to custom loopback domains.
🙏 Please listen to the numerous people on this thread and fix this prevalent issue.