[{"data":1,"prerenderedAt":399},["ShallowReactive",2],{"docs:navigation":3,"docs:page:\u002Fdocs\u002Fdeployment\u002Fsettings":115},[4],{"title":5,"path":6,"stem":7,"children":8,"icon":10},"Introduction","\u002Fdocs","docs\u002F1.index",[9,11,16,21,38,95,110],{"title":5,"path":6,"stem":7,"icon":10},"i-lucide-house",{"title":12,"path":13,"stem":14,"icon":15},"Quickstart","\u002Fdocs\u002Fquickstart","docs\u002F2.quickstart","i-lucide-rocket",{"title":17,"path":18,"stem":19,"icon":20},"Essentials","\u002Fdocs\u002Fconfiguration","docs\u002F3.configuration","i-lucide-book-open",{"title":22,"path":23,"stem":24,"children":25,"icon":27},"Authentication","\u002Fdocs\u002Fauthentication","docs\u002F4.authentication\u002Findex",[26,28,33],{"title":22,"path":23,"stem":24,"icon":27},"i-lucide-shield-check",{"title":29,"path":30,"stem":31,"icon":32},"Protect User Data","\u002Fdocs\u002Fauthentication\u002Fuser-data","docs\u002F4.authentication\u002F1.user-data","i-lucide-user-lock",{"title":34,"path":35,"stem":36,"icon":37},"Two-Factor Verification","\u002Fdocs\u002Fauthentication\u002Ftwo-factor","docs\u002F4.authentication\u002F2.two-factor","i-lucide-key-round",{"title":39,"path":40,"stem":41,"children":42,"icon":44},"Deployment","\u002Fdocs\u002Fdeployment","docs\u002F5.deployment\u002Findex",[43,45,50,55,60,65,70,75,80,85,90],{"title":39,"path":40,"stem":41,"icon":44},"i-lucide-cloud-upload",{"title":46,"path":47,"stem":48,"icon":49},"Deploy to Cloudflare","\u002Fdocs\u002Fdeployment\u002Fcloudflare","docs\u002F5.deployment\u002F1.cloudflare","i-simple-icons-cloudflare",{"title":51,"path":52,"stem":53,"icon":54},"Platform Support","\u002Fdocs\u002Fdeployment\u002Fsupport","docs\u002F5.deployment\u002F10.support","i-lucide-list-checks",{"title":56,"path":57,"stem":58,"icon":59},"Deploy to Vercel","\u002Fdocs\u002Fdeployment\u002Fvercel","docs\u002F5.deployment\u002F2.vercel","i-simple-icons-vercel",{"title":61,"path":62,"stem":63,"icon":64},"Deploy to Azure","\u002Fdocs\u002Fdeployment\u002Fazure","docs\u002F5.deployment\u002F3.azure","i-simple-icons-microsoftazure",{"title":66,"path":67,"stem":68,"icon":69},"Switch Hosts","\u002Fdocs\u002Fdeployment\u002Fswitch-hosts","docs\u002F5.deployment\u002F4.switch-hosts","i-lucide-arrow-right-left",{"title":71,"path":72,"stem":73,"icon":74},"Database and File Storage","\u002Fdocs\u002Fdeployment\u002Fdata-services","docs\u002F5.deployment\u002F5.data-services","i-lucide-database",{"title":76,"path":77,"stem":78,"icon":79},"Domains and Secrets","\u002Fdocs\u002Fdeployment\u002Fsettings","docs\u002F5.deployment\u002F6.settings","i-lucide-settings",{"title":81,"path":82,"stem":83,"icon":84},"Troubleshoot Deployment","\u002Fdocs\u002Fdeployment\u002Ftroubleshooting","docs\u002F5.deployment\u002F7.troubleshooting","i-lucide-wrench",{"title":86,"path":87,"stem":88,"icon":89},"Deploy Agents","\u002Fdocs\u002Fdeployment\u002Fagents","docs\u002F5.deployment\u002F8.agents","i-lucide-bot",{"title":91,"path":92,"stem":93,"icon":94},"Deploy Automations","\u002Fdocs\u002Fdeployment\u002Fautomations","docs\u002F5.deployment\u002F9.automations","i-lucide-workflow",{"title":96,"path":97,"stem":98,"children":99,"icon":101},"Connect Accounts","\u002Fdocs\u002Fconnect","docs\u002F6.connect\u002Findex",[100,102,106],{"title":96,"path":97,"stem":98,"icon":101},"i-lucide-plug",{"title":103,"path":104,"stem":105,"icon":37},"Connection Credentials","\u002Fdocs\u002Fconnect\u002Fcredentials","docs\u002F6.connect\u002F1.credentials",{"title":107,"path":108,"stem":109,"icon":84},"Connect MCP Servers","\u002Fdocs\u002Fconnect\u002Fmcp","docs\u002F6.connect\u002F2.mcp",{"title":111,"path":112,"stem":113,"icon":114},"Project Reference","\u002Fdocs\u002Freference","docs\u002F7.reference","i-lucide-terminal",{"page":116,"surround":394},{"id":117,"title":76,"body":118,"description":387,"extension":388,"links":389,"meta":390,"navigation":391,"path":77,"seo":392,"stem":78,"__hash__":393},"docs\u002Fdocs\u002F5.deployment\u002F6.settings.md",{"type":119,"value":120,"toc":382},"minimark",[121,125,130,133,192,195,226,230,237,248,255,284,287,295,306,317,321,327,353,360,375,378],[122,123,124],"p",{},"Use this page after your application works on its host's default URL. These\nsettings let you move traffic to a stable domain and provide server credentials.",[126,127,129],"h2",{"id":128},"use-your-own-domain","Use Your Own Domain",[122,131,132],{},"On Cloudflare or Vercel, add a hostname to the config:",[134,135,141],"pre",{"className":136,"code":137,"filename":138,"language":139,"meta":140,"style":140},"language-ts shiki shiki-themes github-light github-light github-dark","deploy: {\n  target: 'cloudflare',\n  domain: 'api.example.com',\n}\n","cloud.config.ts","ts","",[142,143,144,157,173,186],"code",{"__ignoreMap":140},[145,146,149,153],"span",{"class":147,"line":148},"line",1,[145,150,152],{"class":151},"snPdu","deploy",[145,154,156],{"class":155},"sxrX7",": {\n",[145,158,160,163,166,170],{"class":147,"line":159},2,[145,161,162],{"class":151},"  target",[145,164,165],{"class":155},": ",[145,167,169],{"class":168},"sIIMD","'cloudflare'",[145,171,172],{"class":155},",\n",[145,174,176,179,181,184],{"class":147,"line":175},3,[145,177,178],{"class":151},"  domain",[145,180,165],{"class":155},[145,182,183],{"class":168},"'api.example.com'",[145,185,172],{"class":155},[145,187,189],{"class":147,"line":188},4,[145,190,191],{"class":155},"}\n",[122,193,194],{},"Use a hostname without a scheme, port, path, or wildcard.",[196,197,198,206,216],"ul",{},[199,200,201,205],"li",{},[202,203,204],"strong",{},"Cloudflare:"," the zone must already exist in the same account. CloudConfig\nkeeps existing routes and adds the hostname as a custom-domain route.",[199,207,208,211,212,215],{},[202,209,210],{},"Vercel:"," use ",[142,213,214],{},"target: 'vercel'",". Deployment assigns the alias, but DNS must\nresolve to Vercel.",[199,217,218,221,222,225],{},[202,219,220],{},"Azure:"," omit ",[142,223,224],{},"deploy.domain",". Automatic hostname and certificate binding is\nnot implemented; use the Azure hostname or bind a domain and certificate in\nAzure separately.",[126,227,229],{"id":228},"set-the-sign-in-origin","Set the Sign-In Origin",[122,231,232,233,236],{},"Set the stable public origin in the ignored ",[142,234,235],{},".env"," file or process environment:",[134,238,242],{"className":239,"code":240,"language":241,"meta":140,"style":140},"language-dotenv shiki shiki-themes github-light github-light github-dark","BETTER_AUTH_URL=https:\u002F\u002Fapp.example.com\n","dotenv",[142,243,244],{"__ignoreMap":140},[145,245,246],{"class":147,"line":148},[145,247,240],{},[122,249,250,251,254],{},"Use the scheme and hostname only, without ",[142,252,253],{},"\u002Fapi\u002Fauth"," or another path. Declare\nthis setting for deployment synchronization:",[134,256,258],{"className":136,"code":257,"filename":138,"language":139,"meta":140,"style":140},"deploy: {\n  secrets: ['BETTER_AUTH_URL'],\n}\n",[142,259,260,266,280],{"__ignoreMap":140},[145,261,262,264],{"class":147,"line":148},[145,263,152],{"class":151},[145,265,156],{"class":155},[145,267,268,271,274,277],{"class":147,"line":159},[145,269,270],{"class":151},"  secrets",[145,272,273],{"class":155},": [",[145,275,276],{"class":168},"'BETTER_AUTH_URL'",[145,278,279],{"class":155},"],\n",[145,281,282],{"class":147,"line":175},[145,283,191],{"class":155},[122,285,286],{},"Register the corresponding callback URL with each sign-in provider. For GitHub:",[134,288,293],{"className":289,"code":291,"language":292,"meta":140},[290],"language-text","https:\u002F\u002Fapp.example.com\u002Fapi\u002Fauth\u002Fcallback\u002Fgithub\n","text",[142,294,291],{"__ignoreMap":140},[122,296,297,298,305],{},"Replace the example origin with your public URL. GitHub supports\n",[299,300,304],"a",{"href":301,"rel":302},"https:\u002F\u002Fgithub.blog\u002Fchangelog\u002F2026-08-14-multiple-redirect-uris-and-token-refresh-for-oauth-apps\u002F",[303],"nofollow","multiple callback URLs",",\nso development and production callbacks can belong to the same OAuth app.",[122,307,308,309,312,313,316],{},"Changing hosts does not update provider registrations automatically. If you use\nTurnstile, update its allowed domains too. Run ",[142,310,311],{},"cloudconfig auth add github","\nafter setting ",[142,314,315],{},"BETTER_AUTH_URL"," to print the resolved callback URL.",[126,318,320],{"id":319},"upload-application-secrets","Upload Application Secrets",[122,322,323,324,326],{},"Declare additional application secrets by name, then supply their values in\n",[142,325,235],{}," or the process environment:",[134,328,330],{"className":136,"code":329,"filename":138,"language":139,"meta":140,"style":140},"deploy: {\n  secrets: ['STRIPE_KEY'],\n}\n",[142,331,332,338,349],{"__ignoreMap":140},[145,333,334,336],{"class":147,"line":148},[145,335,152],{"class":151},[145,337,156],{"class":155},[145,339,340,342,344,347],{"class":147,"line":159},[145,341,270],{"class":151},[145,343,273],{"class":155},[145,345,346],{"class":168},"'STRIPE_KEY'",[145,348,279],{"class":155},[145,350,351],{"class":147,"line":175},[145,352,191],{"class":155},[122,354,355,356,359],{},"The process environment takes precedence. A missing required value stops\ndeployment and names the variable. Keep ",[142,357,358],{},".env.example"," as a template containing\nplaceholders; it is not loaded for development or deployment.",[122,361,362,363,366,367,370,371,374],{},"The ",[142,364,365],{},"auth"," and ",[142,368,369],{},"connect"," blocks determine their own required secret names. You\ndo not need to list those credentials again in ",[142,372,373],{},"deploy.secrets",".",[122,376,377],{},"For CI, provide values through the CI secret store. Keep credentials out of\nsource files and committed environment files.",[379,380,381],"style",{},"html pre.shiki code .snPdu, html code.shiki .snPdu{--shiki-light:#6F42C1;--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sxrX7, html code.shiki .sxrX7{--shiki-light:#24292E;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .sIIMD, html code.shiki .sIIMD{--shiki-light:#032F62;--shiki-default:#032F62;--shiki-dark:#9ECBFF}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":140,"searchDepth":159,"depth":159,"links":383},[384,385,386],{"id":128,"depth":159,"text":129},{"id":228,"depth":159,"text":229},{"id":319,"depth":159,"text":320},"Set the public origin, use your own domain, and provide application secrets.","md",null,{},{"icon":79},{"title":76,"description":387},"bbp25H5aD5vRTDdMrCcihmmLNh6oJfb0u12zRlp0vK8",[395,397],{"title":71,"path":72,"stem":73,"description":396,"icon":74},"Configure production data services independently of the application host.",{"title":81,"path":82,"stem":83,"description":398,"icon":84},"Identify migration, credential, and runtime problems before retrying deployment.",1792122403758]