{"id":428,"date":"2024-06-15T19:14:59","date_gmt":"2024-06-15T19:14:59","guid":{"rendered":"https:\/\/javawebhosting.co.in\/kb\/?p=428"},"modified":"2024-06-15T20:26:03","modified_gmt":"2024-06-15T20:26:03","slug":"cpanel","status":"publish","type":"post","link":"https:\/\/javawebhosting.co.in\/kb\/cpanel\/","title":{"rendered":"How to change default index page in cPanel"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\" id=\"what-is-c-panel\">What is cPanel<\/h2>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"525\" src=\"https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-8-1024x525.png\" alt=\"\" class=\"wp-image-432\" style=\"width:458px;height:auto\" srcset=\"https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-8-1024x525.png 1024w, https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-8-300x154.png 300w, https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-8-768x394.png 768w, https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-8.png 1204w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n<\/div>\n\n\n<p>cPanel is a popular web hosting control panel that provides a graphical interface and automation tools designed to simplify the process of hosting a website. It allows users to manage their web hosting accounts and perform various administrative tasks without needing to have extensive technical knowledge.<\/p>\n\n\n\n<div class=\"wp-block-rank-math-toc-block\" id=\"rank-math-toc\"><h2>Table of Contents<\/h2><nav><ul><li><a href=\"#what-is-c-panel\">What is cPanel<\/a><\/li><li><a href=\"#how-to-change-default-index-page-in-c-panel\">How to change default index page in cPanel<\/a><\/li><li><a href=\"#what-are-the-reasons-for-showing-wrong-index-page\">What are the Reasons for showing wrong index page<\/a><ul><li><a href=\"#1-browser-caching\">1. Browser Caching<\/a><\/li><li><a href=\"#2-server-caching\">2. Server Caching<\/a><\/li><li><a href=\"#3-htaccess-configuration\">3. .htaccess Configuration<\/a><\/li><li><a href=\"#4-file-naming-and-priority\">4. File Naming and Priority<\/a><\/li><li><a href=\"#5-incorrect-file-upload\">5. Incorrect File Upload<\/a><\/li><li><a href=\"#6-dns-propagation\">6. DNS Propagation<\/a><\/li><li><a href=\"#7-permissions-issues\">7. Permissions Issues<\/a><\/li><li><a href=\"#8-symlinks-and-redirects\">8. Symlinks and Redirects<\/a><\/li><li><a href=\"#9-server-configuration\">9. Server Configuration<\/a><\/li><li><a href=\"#10-cms-settings\">10. CMS Settings<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"how-to-change-default-index-page-in-c-panel\">How to change default index page in cPanel<\/h2>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"539\" height=\"426\" src=\"https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/how-to-change-default-index-page-in-htaccess-from-cpanel-5.webp\" alt=\"cPanel\" class=\"wp-image-433\" style=\"width:367px;height:auto\" srcset=\"https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/how-to-change-default-index-page-in-htaccess-from-cpanel-5.webp 539w, https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/how-to-change-default-index-page-in-htaccess-from-cpanel-5-300x237.webp 300w\" sizes=\"auto, (max-width: 539px) 100vw, 539px\" \/><\/figure>\n<\/div>\n\n\n<p>To change the default index page in cPanel, follow these steps:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Log in to cPanel:<\/strong>\n<ul class=\"wp-block-list\">\n<li>Open your web browser and navigate to your cPanel login page. It usually looks something like <code>yourdomain.com\/cpanel<\/code>.<\/li>\n\n\n\n<li>Enter your cPanel username and password to log in.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><strong>Open the File Manager:<\/strong>\n<ul class=\"wp-block-list\">\n<li>In the cPanel dashboard, look for the &#8220;Files&#8221; section.<\/li>\n\n\n\n<li>Click on &#8220;File Manager.&#8221;<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><strong>Navigate to the Public_HTML Directory:<\/strong>\n<ul class=\"wp-block-list\">\n<li>In the File Manager, navigate to the <code>public_html<\/code> directory. This is the root directory for your website.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><strong>Edit or Rename the Default Index File:<\/strong>\n<ul class=\"wp-block-list\">\n<li>Look for the current default index file, which is usually named <code>index.html<\/code>, <code>index.php<\/code>, or something similar.<\/li>\n\n\n\n<li>If you want to change the default page, you can either rename this file or delete it.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><strong>Upload or Create Your New Index File:<\/strong>\n<ul class=\"wp-block-list\">\n<li>If you have a new index file (e.g., <code>home.html<\/code> or <code>welcome.php<\/code>), upload it to the <code>public_html<\/code> directory.<\/li>\n\n\n\n<li>You can upload the file by clicking the &#8220;Upload&#8221; button in the File Manager and selecting your file from your computer.<\/li>\n\n\n\n<li>Alternatively, you can create a new file directly in the File Manager by clicking on the &#8220;+ File&#8221; button and naming your new index file.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><strong>Update the .htaccess File (Optional):<\/strong>\n<ul class=\"wp-block-list\">\n<li>If you want to specify a different file as the default index page, you can update your <code>.htaccess<\/code> file.<\/li>\n\n\n\n<li>In the <code>public_html<\/code> directory, look for the <code>.htaccess<\/code> file. If you don&#8217;t see it, you may need to enable the option to show hidden files (dotfiles) in the File Manager settings.<\/li>\n\n\n\n<li>Edit the <code>.htaccess<\/code> file by right-clicking on it and selecting &#8220;Edit.&#8221;<\/li>\n\n\n\n<li>Add the following line to the top of the file, replacing <code>yourpage.html<\/code> with the name of your new index file:<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"956\" height=\"59\" src=\"https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-5.png\" alt=\"\" class=\"wp-image-429\" style=\"width:840px;height:auto\" srcset=\"https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-5.png 956w, https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-5-300x19.png 300w, https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-5-768x47.png 768w\" sizes=\"auto, (max-width: 956px) 100vw, 956px\" \/><\/figure>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Save the changes to the <code>.htaccess<\/code> file.<\/li>\n<\/ul>\n\n\n\n<p>By following these steps, you can successfully change the default index page for your website in cPanel.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"what-are-the-reasons-for-showing-wrong-index-page\">What are the Reasons for showing wrong index page<\/h2>\n\n\n\n<p>Several reasons might cause a web server to show the wrong index page. Here are some common issues and how to address them:<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"1-browser-caching\">1. <strong>Browser Caching<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> Your browser might be displaying a cached version of the old index page.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Clear your browser cache or use an incognito\/private browsing window to check the site.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"2-server-caching\">2. <strong>Server Caching<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> Server-side caching (e.g., from a caching plugin or CDN) might be serving an outdated version of the index page.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Clear any server-side caches, including those from CDNs like Cloudflare.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"3-htaccess-configuration\">3. <strong>.htaccess Configuration<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> Incorrect <code>.htaccess<\/code> settings can lead to the wrong file being served as the index page.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Check your <code>.htaccess<\/code> file for the <code>DirectoryIndex<\/code> directive and ensure it points to the correct file:<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"931\" height=\"63\" src=\"https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-6.png\" alt=\"\" class=\"wp-image-430\" style=\"width:840px;height:auto\" srcset=\"https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-6.png 931w, https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-6-300x20.png 300w, https:\/\/javawebhosting.co.in\/kb\/wp-content\/uploads\/2024\/06\/image-6-768x52.png 768w\" sizes=\"auto, (max-width: 931px) 100vw, 931px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"4-file-naming-and-priority\">4. <strong>File Naming and Priority<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> Web servers typically have a default order for index files (e.g., <code>index.html<\/code>, <code>index.php<\/code>). If multiple index files exist, the server might serve the wrong one.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Ensure that only the desired index file is present or rename it to match the server&#8217;s default index file name.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"5-incorrect-file-upload\">5. <strong>Incorrect File Upload<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> The wrong file might have been uploaded or the file might be in the wrong directory.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Verify that the correct index file is uploaded to the <code>public_html<\/code> directory.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"6-dns-propagation\">6. <strong>DNS Propagation<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> If you recently updated your <a href=\"http:\/\/javawebhosting.co.in\">domain&#8217;s<\/a> DNS settings, the changes might not have fully propagated yet, leading to old content being served.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Wait for DNS propagation to complete (this can take up to 48 hours).<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"7-permissions-issues\">7. <strong>Permissions Issues<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> Incorrect file permissions might prevent the server from accessing the correct index file.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Ensure the index file has the correct permissions (typically 644 for files and 755 for directories).<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"8-symlinks-and-redirects\">8. <strong>Symlinks and Redirects<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> Symlinks or redirects in the <code>.htaccess<\/code> file or server configuration might point to a different file.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Check for and correct any symlinks or redirect rules.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"9-server-configuration\">9. <strong>Server Configuration<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> The server might be configured incorrectly to serve a different index file.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Check the server configuration (e.g., Apache&#8217;s <code>httpd.conf<\/code> or Nginx&#8217;s <code>nginx.conf<\/code>) to ensure it points to the correct index file.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"10-cms-settings\">10. <strong>CMS Settings<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Issue:<\/strong> If you\u2019re using a Content Management System (CMS) like WordPress, the CMS settings might point to a different homepage.<\/li>\n\n\n\n<li><strong>Solution:<\/strong> Check the CMS settings to ensure the correct page is set as the homepage.<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>What is cPanel cPanel is a popular web hosting control panel that provides a graphical interface and automation tools designed to simplify<\/p>\n<p class=\"link-more\"><a class=\"myButt \" href=\"https:\/\/javawebhosting.co.in\/kb\/cpanel\/\">Read More<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[37],"tags":[],"class_list":["post-428","post","type-post","status-publish","format-standard","hentry","category-how-to-change-default-index-page-in-cpanel"],"_links":{"self":[{"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/posts\/428","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/comments?post=428"}],"version-history":[{"count":1,"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/posts\/428\/revisions"}],"predecessor-version":[{"id":434,"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/posts\/428\/revisions\/434"}],"wp:attachment":[{"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/media?parent=428"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/categories?post=428"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/javawebhosting.co.in\/kb\/wp-json\/wp\/v2\/tags?post=428"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}