{"record":{"id":"f84f9870dfa6c1c2","repo":"cloudflare/cloudflared","slug":"tunnelcmderrormessage","errorCode":"tunnelCmdErrorMessage","errorMessage":"You did not specify any valid additional argument to the cloudflared tunnel command.\n\nIf you are trying to run a Quick Tunnel then you need to explicitly pass the --url flag.\nEg. cloudflared tunnel --url localhost:8080/.\n\nPlease note that Quick Tunnels are meant to be ephemeral and should only be used for testing purposes.\nFor production usage, we recommend creating Named Tunnels. (https://developers.cloudflare.com/cloudflare-one/connections/connect-apps/install-and-setup/tunnel-guide/)\n","messagePattern":"You did not specify any valid additional argument to the cloudflared tunnel command\\.\n\nIf you are trying to run a Quick Tunnel then you need to explicitly pass the --url flag\\.\nEg\\. cloudflared tunnel --url localhost:8080/\\.\n\nPlease note that Quick Tunnels are meant to be ephemeral and should only be used for testing purposes\\.\nFor production usage, we recommend creating Named Tunnels\\. \\(https://developers\\.cloudflare\\.com/cloudflare-one/connections/connect-apps/install-and-setup/tunnel-guide/\\)\n","errorType":"error_code","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cmd/cloudflared/tunnel/cmd.go","lineNumber":270,"sourceCode":"\n\t// Run a quick tunnel\n\t// A unauthenticated named tunnel hosted on <random>.<quick-tunnels-service>.com\n\tshouldRunQuickTunnel := c.IsSet(\"url\") || c.IsSet(ingress.HelloWorldFlag)\n\tif c.String(\"quick-service\") != \"\" && shouldRunQuickTunnel {\n\t\treturn RunQuickTunnel(sc)\n\t}\n\n\t// If user provides a config, check to see if they meant to use `tunnel run` instead\n\tif ref := config.GetConfiguration().TunnelID; ref != \"\" {\n\t\treturn fmt.Errorf(\"use `cloudflared tunnel run` to start tunnel %s\", ref)\n\t}\n\n\t// Classic tunnel usage is no longer supported\n\tif c.String(\"hostname\") != \"\" {\n\t\treturn errDeprecatedClassicTunnel\n\t}\n\n\treturn errors.New(tunnelCmdErrorMessage)\n}\n\nfunc Init(info *cliutil.BuildInfo, gracefulShutdown chan struct{}) {\n\tbuildInfo, graceShutdownC = info, gracefulShutdown\n}\n\n// runAdhocNamedTunnel create, route and run a named tunnel in one command\nfunc runAdhocNamedTunnel(sc *subcommandContext, name, credentialsOutputPath string) error {\n\ttunnel, ok, err := sc.tunnelActive(name)\n\tif err != nil || !ok {\n\t\t// pass empty string as secret to generate one\n\t\ttunnel, err = sc.create(name, credentialsOutputPath, \"\")\n\t\tif err != nil {\n\t\t\treturn errors.Wrap(err, \"failed to create tunnel\")\n\t\t}\n\t} else {\n\t\tsc.log.Info().Str(LogFieldTunnelID, tunnel.ID.String()).Msg(\"Reusing existing tunnel with this name\")\n\t}","sourceCodeStart":252,"sourceCodeEnd":288,"githubUrl":"https://github.com/cloudflare/cloudflared/blob/2253eeeb25a44a713a4b60b8ba1e1b3f377d1a0f/cmd/cloudflared/tunnel/cmd.go#L252-L288","documentation":"TunnelCommand returns this error when the `cloudflared tunnel` subcommand receives no valid arguments (no hostname rule, no --url). Classic tunnel usage (setting `hostname` without `url`) is deprecated and also rejected first with errDeprecatedClassicTunnel. Quick Tunnels require an explicit --url flag; without it there is nothing for the command to do.","triggerScenarios":"Running `cloudflared tunnel` with no --url and no ingress hostname; or setting `hostname` which triggers the deprecated classic-tunnel check before this error.","commonSituations":"Users following old classic-tunnel tutorials; users expecting Quick Tunnel to start without --url; shell scripts that dropped the --url argument.","solutions":["Pass --url, e.g. `cloudflared tunnel --url localhost:8080` for a Quick Tunnel (testing only).","For production, create a Named Tunnel: `cloudflared tunnel create <name>`, add ingress rules to the config file, and run `cloudflared tunnel run <name>`.","Remove the deprecated `hostname`-only classic tunnel configuration; classic tunnels are no longer supported."],"exampleFix":"// before\ncloudflared tunnel\n// after\ncloudflared tunnel --url localhost:8080","handlingStrategy":"validation","validationCode":"if [ $# -eq 0 ]; then echo \"usage: cloudflared tunnel --url <addr> | cloudflared tunnel run <name>\" >&2; exit 1; fi","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Always pass --url for Quick Tunnels in scripts and docs.","Use `cloudflared tunnel run <name>` for Named Tunnels instead of bare `tunnel`.","Migrate legacy hostname-based classic tunnel configs to ingress rules."],"tags":["cli","tunnel","missing-flag","quick-tunnel"],"backgroundTag":"missing-required-flag","analyzedSha":"2253eeeb25a44a713a4b60b8ba1e1b3f377d1a0f","analyzedAt":"2026-09-06T04:14:33.757Z","contentChangedAt":"2026-09-06T04:14:33.757Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}