{"id":10552,"date":"2026-05-13T06:22:56","date_gmt":"2026-05-13T06:22:56","guid":{"rendered":"https:\/\/www.hostinger.com\/support\/?p=10552"},"modified":"2026-05-13T06:22:56","modified_gmt":"2026-05-13T06:22:56","slug":"how-to-change-the-domain-of-a-docker-project","status":"publish","type":"post","link":"https:\/\/www.hostinger.com\/support\/how-to-change-the-domain-of-a-docker-project\/","title":{"rendered":"How to change the domain of a Docker project"},"content":{"rendered":"<p>When you deploy an application like n8n or OpenClaw from the Hostinger Docker Catalog, it is assigned a default temporary hostname (e.g., n8n-xxxx.srv123.hstgr.cloud). To use your own custom domain (e.g., n8n.example.com) with full HTTPS (SSL) support, you must update the project&rsquo;s configuration and configure your DNS settings.<\/p><h2 id=\"h-step-1-prepare-your-dns-cloudflare-or-other-providers\">Step 1: Prepare your DNS (Cloudflare or other providers)<\/h2><p>Before changing the configuration in hPanel, your domain must point to your server:<\/p><ol>\n<li>Create an A record for your desired subdomain (e.g., n8n).<\/li>\n<li>Set the Content\/Target to your VPS IP address.<\/li>\n<li><strong>Important<\/strong>: If using Cloudflare, set the Proxy status to DNS-only (gray cloud) during the initial setup. You can reactivate the proxy (orange cloud) once the SSL certificate is successfully issued.<\/li>\n<\/ol><h2 id=\"h-step-2-update-the-docker-compose-configuration\">Step 2: Update the Docker Compose configuration<\/h2><p>You must tell the Docker container to listen for requests coming from your custom domain instead of the temporary one.<\/p><ol>\n<li>Go to your <strong>hPanel &rarr; VPS &rarr; Manage<\/strong>.<\/li>\n<li>Navigate to the<strong> Docker Manager<\/strong> section.<\/li>\n<li>Locate your active project (e.g., n8n) and click the <strong>Manage<br>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10553\" src=\"https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-14.png\" alt=\"\" width=\"1639\" height=\"558\" srcset=\"https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-14.png 1639w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-14-300x102.png 300w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-14-1024x349.png 1024w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-14-768x261.png 768w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-14-1536x523.png 1536w\" sizes=\"auto, (max-width: 1639px) 100vw, 1639px\" \/><br>\n<\/strong><\/li>\n<li>Then access the<strong> .yaml editor<\/strong>.\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10554\" src=\"https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-18.png\" alt=\"\" width=\"1654\" height=\"776\" srcset=\"https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-18.png 1654w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-18-300x141.png 300w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-18-1024x480.png 1024w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-18-768x360.png 768w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-18-1536x721.png 1536w\" sizes=\"auto, (max-width: 1654px) 100vw, 1654px\" \/><\/p><\/li>\n<li>Locate the labels section in the YAML file. Look for lines mentioning Host rules.<\/li>\n<li>Change the default hostname to your custom domain in the following places:\n<ul>\n<li>traefik.http.routers.[project-name].rule=Host(&lsquo;yourdomain.com&rsquo;)<\/li>\n<li>traefik.http.routers.[project-name]-secure.rule=Host(&lsquo;yourdomain.com&rsquo;)<br>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10555\" src=\"https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-20.png\" alt=\"\" width=\"1084\" height=\"560\" srcset=\"https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-20.png 1084w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-20-300x155.png 300w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-20-1024x529.png 1024w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-20-768x397.png 768w\" sizes=\"auto, (max-width: 1084px) 100vw, 1084px\" \/><\/li>\n<\/ul>\n<\/li>\n<li>Deploy the container to apply the changes.<br>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10556\" src=\"https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-22.png\" alt=\"\" width=\"1158\" height=\"776\" srcset=\"https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-22.png 1158w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-22-300x201.png 300w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-22-1024x686.png 1024w, https:\/\/www.hostinger.com\/support\/wp-content\/uploads\/sites\/55\/2026\/05\/2026-05-13_13-22-768x515.png 768w\" sizes=\"auto, (max-width: 1158px) 100vw, 1158px\" \/><\/li>\n<\/ol><h2 id=\"h-step-3-verify-ssl-and-connectivity\">Step 3: Verify SSL and Connectivity<\/h2><p>Once redeployed, Traefik will automatically attempt to issue a Let&rsquo;s Encrypt SSL certificate for your new domain.<\/p><ol>\n<li>Wait 1&ndash;3 minutes for the SSL handshake to complete.<\/li>\n<li>Open your site in an Incognito\/Private window to avoid cached errors.<\/li>\n<li>If you encounter an ERR_TOO_MANY_REDIRECTS error, ensure your Cloudflare SSL\/TLS encryption mode is set to Full (strict) or that the Cloudflare proxy is temporarily disabled.<\/li>\n<\/ol><p>By updating the Traefik Host labels in your Docker configuration, you can easily transition from a temporary development URL to a professional custom domain. This setup ensures that your Docker applications remain secure with automated HTTPS certificates.<\/p><p>&nbsp;<\/p><div class=\"intercom-interblocks-callout\" style=\"background-color: #e3e7fa80;border-color: #334bfa33\">\n<p><strong>Notes<\/strong>:<\/p>\n<ul>\n<li><strong>SSL Renewal:<\/strong> If you use Cloudflare proxies, you may need to briefly disable them or restart the Traefik container every 3 months to allow SSL certificates to renew.<\/li>\n<li><strong>Port Conflicts:<\/strong> Do not change the internal container ports unless you are an advanced user, as this can break the reverse proxy routing.<\/li>\n<li><strong>Backups<\/strong>: Before making changes to your YAML configuration, it is highly recommended to create a VPS Snapshot as a recovery point.<\/li>\n<\/ul>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Learn how to point your custom domain to a Docker application using the Hostinger Docker Manager and a reverse proxy.<\/p>\n","protected":false},"author":594,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"include_on_kodee":true,"footnotes":""},"categories":[297],"tags":[],"class_list":["post-10552","post","type-post","status-publish","format-standard","hentry","category-docker-manager"],"hreflangs":[],"include_on_kodee":true,"_links":{"self":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/10552","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/users\/594"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/comments?post=10552"}],"version-history":[{"count":2,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/10552\/revisions"}],"predecessor-version":[{"id":10558,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/10552\/revisions\/10558"}],"wp:attachment":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/media?parent=10552"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/categories?post=10552"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/tags?post=10552"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}