{"id":2332,"date":"2024-06-02T16:22:33","date_gmt":"2024-06-02T13:22:33","guid":{"rendered":"https:\/\/www.fibacloud.com\/community\/tutorials\/?p=2332"},"modified":"2026-10-04T22:57:46","modified_gmt":"2026-10-04T19:57:46","slug":"how-to-publish-a-website-with-cpanel-step-by-step-guide","status":"publish","type":"post","link":"https:\/\/www.fibacloud.com\/community\/tutorials\/en\/how-to-publish-a-website-with-cpanel-step-by-step-guide\/","title":{"rendered":"Publish a Website with cPanel: DNS, HTTPS and Backups"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"2332\" class=\"elementor elementor-2332\" data-elementor-post-type=\"post\">\n\t\t\t\t<div class=\"elementor-element elementor-element-fab753b e-con-full e-flex e-con e-parent\" data-id=\"fab753b\" data-element_type=\"container\">\n\t\t\t\t<div class=\"elementor-element elementor-element-debaa2f elementor-widget elementor-widget-text-editor\" data-id=\"debaa2f\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<style>\/*! elementor - v3.21.0 - 08-05-2024 *\/\n.elementor-widget-text-editor.elementor-drop-cap-view-stacked .elementor-drop-cap{background-color:#69727d;color:#fff}.elementor-widget-text-editor.elementor-drop-cap-view-framed .elementor-drop-cap{color:#69727d;border:3px solid;background-color:transparent}.elementor-widget-text-editor:not(.elementor-drop-cap-view-default) .elementor-drop-cap{margin-top:8px}.elementor-widget-text-editor:not(.elementor-drop-cap-view-default) .elementor-drop-cap-letter{width:1em;height:1em}.elementor-widget-text-editor .elementor-drop-cap{float:left;text-align:center;line-height:1;font-size:50px}.elementor-widget-text-editor .elementor-drop-cap-letter{display:inline-block}<\/style>\t\t\t\t<p>Publishing with cPanel means checking the domain, document root, application database and HTTPS certificate together. This guide covers publishing a new website in an existing cPanel account while protecting other sites in that account. It does not install cPanel or migrate an entire server.<\/p>\n<figure class=\"fc-editorial-figure\" data-fc-visual=\"20260920\" aria-labelledby=\"fc-editorial-caption-2332\"><a href=\"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-content\/uploads\/community-editorial-20260920\/fc-cpanel-en-inline-20260920.webp\" target=\"_blank\" rel=\"noopener\" aria-label=\"Open full-size illustration\"><picture><source media=\"(max-width: 600px)\" srcset=\"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-content\/uploads\/community-editorial-20260920\/fc-cpanel-en-mobile-20260920.webp\" width=\"720\" height=\"1140\"><img loading=\"lazy\" src=\"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-content\/uploads\/community-editorial-20260920\/fc-cpanel-en-inline-20260920.webp\" srcset=\"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-content\/uploads\/community-editorial-20260920\/fc-cpanel-en-inline-20260920.webp 1440w, https:\/\/www.fibacloud.com\/community\/tutorials\/wp-content\/uploads\/community-editorial-20260920\/fc-cpanel-en-inline-20260920-300x242.webp 300w, https:\/\/www.fibacloud.com\/community\/tutorials\/wp-content\/uploads\/community-editorial-20260920\/fc-cpanel-en-inline-20260920-1024x825.webp 1024w, https:\/\/www.fibacloud.com\/community\/tutorials\/wp-content\/uploads\/community-editorial-20260920\/fc-cpanel-en-inline-20260920-768x619.webp 768w\" sizes=\"auto, (max-width: 900px) 100vw, 820px\" width=\"1440\" height=\"1160\" alt=\"How a request reaches your site\" class=\"wp-image-2536\"  decoding=\"async\"><\/picture><\/a><figcaption id=\"fc-editorial-caption-2332\"><strong>How a request reaches your site<\/strong> DNS resolves the domain to a server address. HTTPS verifies the certificate; the web server serves the configured document root for the hostname.<details><summary>Step-by-step explanation<\/summary><ol><li>Resolve: Point DNS to the server address.<\/li><li>Upload: Place files in the correct document root.<\/li><li>Secure: Install a certificate for the domain.<\/li><li>Verify: Check DNS, HTTPS and page responses.<\/li><\/ol><\/details><\/figcaption><\/figure>\n<h2>Before you begin<\/h2>\n<ul>\n<li>Obtain access to the domain&#8217;s DNS settings and the correct cPanel account. Use the panel address provided by your host and investigate certificate warnings before signing in.<\/li>\n<li>Back up the current files and database. Keep backups outside publicly accessible website directories.<\/li>\n<li>Check the application&#8217;s supported PHP version, required extensions and database requirements in its own documentation.<\/li>\n<li>For a migration, prepare a separate test environment before changing DNS. Keep the previous server until the new site passes acceptance checks.<\/li>\n<\/ul>\n<p>Menu names depend on the cPanel version and features enabled by the provider. This article is not a record of an end-to-end installation in a licensed panel; complete the checks below in your own test account.<\/p>\n<h2>1. Identify the domain and its actual document root<\/h2>\n<p>Open <strong>Domains<\/strong> and find the <strong>Document Root<\/strong> for the domain you intend to publish. The primary domain commonly uses <code>public_html<\/code>; additional domains can use a different directory or share an existing root. Do not automatically upload every website into <code>public_html<\/code>.<\/p>\n<p>When adding a domain, choose whether to share another domain&#8217;s root deliberately. Accidentally selecting an existing site&#8217;s directory can overwrite its files. Removing a domain from the panel is also different from safely removing its website files.<\/p>\n<p>Verify that its A record and any AAAA record point to the intended server. An unwanted AAAA record can send IPv6 visitors to a different site even when IPv4 works. If another provider hosts the authoritative DNS zone, make the change there.<\/p>\n<h2>2. Upload files into the correct directory<\/h2>\n<p>Follow the directory link in Domains to <strong>File Manager<\/strong>. Upload the application there. If extracting an archive, make sure <code>index.html<\/code> or <code>index.php<\/code> is not left inside an unintended extra directory.<\/p>\n<p>Do not expose configuration secrets, source archives, <code>.git<\/code> directories or SQL backups. Do not solve permission problems by granting <code>777<\/code> to the whole tree. Ownership and writable directories depend on the application&#8217;s requirements and the account&#8217;s PHP execution model.<\/p>\n<p>For large transfers, use SFTP or FTPS with required TLS when your account supports them. Plain FTP does not protect passwords or file contents. Compare important file sizes or hashes with the source after uploading.<\/p>\n<h2>3. Create the application database and user<\/h2>\n<p>A static HTML site does not need a database. For a database-backed application, open <strong>Manage My Databases<\/strong>, called <strong>MySQL\u00ae Databases<\/strong> in older versions.<\/p>\n<ol>\n<li>Create a separate database for the application.<\/li>\n<li>Create a separate user with a strong, unique password.<\/li>\n<li>Add that user only to this database. Grant the privileges required by the application&#8217;s installation or schema migration process; avoid a shared administrator account.<\/li>\n<li>Copy the complete names displayed by the panel into the application configuration. Account prefixes can make them different from the short names you entered.<\/li>\n<li>Verify the database hostname with the provider instead of assuming every account uses <code>localhost<\/code>.<\/li>\n<\/ol>\n<p>Import existing data into a separate empty database. In phpMyAdmin, verify the selected database before importing; do not overwrite live data with an unverified dump. Keep the database password out of public pages, support messages and Git repositories.<\/p>\n<h2>4. Configure HTTPS and the application runtime<\/h2>\n<p>In <strong>SSL\/TLS Status<\/strong>, check the domain and any names you use, such as <code>www<\/code>. If AutoSSL is enabled for the account, inspect the certificate request result. DNS and validation requirements must be satisfied first, and feature availability depends on the provider.<\/p>\n<p>Once the domain serves a valid HTTPS certificate, set the application&#8217;s public URL to HTTPS. Use the supported Domains redirect setting or the application&#8217;s documented redirect method. Avoid conflicting redirect rules in multiple layers.<\/p>\n<p>Select a PHP version supported by the application using <strong>MultiPHP Manager<\/strong> or the provider&#8217;s equivalent tool. A higher version number alone does not demonstrate application compatibility.<\/p>\n<h2>5. Complete publication checks<\/h2>\n<ul>\n<li>The domain and preferred <code>www<\/code> variant open the intended site. HTTP redirects to the correct HTTPS URL.<\/li>\n<li>The certificate name and chain are valid, with no mixed HTTP content in the browser.<\/li>\n<li>The homepage, an internal page and a nonexistent URL return the expected response. A missing URL should not masquerade as a successful page with HTTP 200.<\/li>\n<li>Required login, form, upload and database write operations work using a test account.<\/li>\n<li>SQL backups, configuration secrets and directory listings are not publicly accessible.<\/li>\n<\/ul>\n<p>Keep the existing URLs when migrating a website. If an address must change, prepare a 301 redirect to the relevant replacement. Ensure that a test environment&#8217;s <code>noindex<\/code> setting or password protection has not accidentally been carried into the public site.<\/p>\n<h2>Troubleshooting and rollback<\/h2>\n<p><strong>Wrong site or 404:<\/strong> check DNS, Document Root and the archive&#8217;s directory depth. <strong>500 response:<\/strong> inspect cPanel error logs, the PHP version and application permissions without exposing detailed errors to visitors. <strong>Database connection failure:<\/strong> check the complete database\/user names, hostname, password and user-to-database association. <strong>Certificate failure:<\/strong> check DNS, all requested domain names and the AutoSSL result.<\/p>\n<p>Preserve a matching copy of the old application files and database. Reverting code alone does not undo a schema migration. Restore backups into a separate test directory and database before relying on them. cPanel <strong>Backup Wizard<\/strong> can restore partial backups; automatic restoration of a full account backup requires WHM or the hosting provider rather than the cPanel user interface. DNS rollback can also be delayed by resolver caches.<\/p>\n<h2>Official references<\/h2>\n<ul>\n<li><a href=\"https:\/\/docs.cpanel.net\/cpanel\/domains\/domains\/\" rel=\"nofollow noopener\" target=\"_blank\">cPanel Domains and document roots<\/a><\/li>\n<li><a href=\"https:\/\/docs.cpanel.net\/cpanel\/databases\/manage-my-databases\/\" rel=\"nofollow noopener\" target=\"_blank\">Manage My Databases and user privileges<\/a><\/li>\n<li><a href=\"https:\/\/docs.cpanel.net\/cpanel\/security\/ssl-tls-status\/\" rel=\"nofollow noopener\" target=\"_blank\">SSL\/TLS Status and AutoSSL<\/a><\/li>\n<li><a href=\"https:\/\/docs.cpanel.net\/cpanel\/files\/backup-wizard\/\" rel=\"nofollow noopener\" target=\"_blank\">Backup Wizard: full and partial backups<\/a><\/li>\n<\/ul>\n<p class=\"fc-article-review-date\">Technical content and sources reviewed on October 4, 2026. Recheck the relevant official documentation when a version or provider changes.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>Publish a site with cPanel: verify its document root, upload files, configure a database and HTTPS, then test backups and rollback.<\/p>\n","protected":false},"author":1,"featured_media":2535,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[210,214,212],"class_list":["post-2332","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tutorials-en","tag-cpanel","tag-hosting","tag-website-management"],"lang":"en","translations":{"en":2332,"tr":1718},"pll_sync_post":[],"_links":{"self":[{"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/posts\/2332","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/comments?post=2332"}],"version-history":[{"count":5,"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/posts\/2332\/revisions"}],"predecessor-version":[{"id":2337,"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/posts\/2332\/revisions\/2337"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/media\/2535"}],"wp:attachment":[{"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/media?parent=2332"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/categories?post=2332"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.fibacloud.com\/community\/tutorials\/wp-json\/wp\/v2\/tags?post=2332"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}