Website Shows "Index of /" or a Default Server Page Instead of Your Site?

Short answer
What does it mean when my website shows "Index of /"?
An Index of page is a directory listing that a web server builds when a folder has no homepage file. The server looks for a file such as index.html or index.php. If none exists and listing is on, it lists the folder. So your files are missing, misplaced, or the server expects another file name.
You type in your domain. Instead of your website, you get a plain file list titled "Index of /" or a welcome page you have never seen. An Index of page means the web server could not find a homepage file, so it listed the folder contents instead. A default server page means your domain points to a server space that does not hold your site files. This guide helps you tell which one you have, who fixes it and how to keep it from happening again.
That screen rightly alarms a business owner: a customer opens your site and sees file names instead of your products. However, in most cases you have lost nothing. The files usually sit somewhere on the server or in a backup. The real job is finding out why the server cannot see them.
- Is the list empty, or does it contain folder and file names?
- Do you see an unexpected folder such as "public_html", "site" or the name of a zip file?
- Did the problem start after you changed your domain or server?
- Do you get the same screen with and without "www"?
How is an Index of page different from a default server page?
People often mix them up; however, they tell different stories. An Index of listing shows that the server is looking at the right folder but cannot find a homepage file there. A default server page, on the other hand, means the server does not recognize your site at all, so it shows its own placeholder.
In practice, default pages come in several forms. For example, a fresh Apache or Nginx server may show a test page. Its heading reads along the lines of "it works" or "welcome". Hosting providers also show their own landing page when a domain is not yet attached to an account. The wording changes by version and provider. So rather than searching for an exact heading, check whether the page carries your content.
A maintenance page is a different case entirely. If your site deliberately shows a temporary page, our guide on the maintenance mode page and the 503 status code covers it. If nothing loads and the screen stays blank, see our guide to the blank white screen instead.
What is the page telling you, and who fixes it?
The diagnostic table below pairs what you see on screen with its likely meaning and with who holds the fix. The last column is honest about the split: some of these you can fix in your file manager, while others need server configuration.
| What you see | Likely meaning | Who fixes it? |
|---|---|---|
| Index of / with an empty list | No files in the root folder; nothing uploaded or files deleted | You, if you have a backup; otherwise a developer and hosting support |
| Index of / with a single folder | You uploaded the files into a subfolder | You, with the file manager |
| Index of / with files but no index | The homepage file has another name or the server does not look for it | You for the file name; a developer for the setting |
| Index of listing inside a subfolder | Directory listing is on and a folder without a homepage is exposed | Developer or server administrator |
| Apache or Nginx test page | The server does not recognize your site; configuration missing | Server administrator |
| Hosting provider landing page | Domain points to the new server, but your files are not there | You and hosting support |
| Site on some devices, default page on others | The DNS change has not reached everyone yet | Wait and verify the records |
What should you check in the first five minutes of an Index of problem?
These steps need no server knowledge; access to your hosting control panel is enough. The goal is to separate a file issue from a setting issue or a domain issue.
- Open the file manager in your hosting panel and find the document root for your domain. The document root is the main folder where the server looks for your site; many panels call it public_html.
- Check whether index.html or index.php exists in that folder.
- If not, look inside any subfolder: do your site files sit there?
- Next, check in the domain settings of your panel which folder the document root points to.
- Finally, check which server your DNS record points to. Does it match the IP address shown in your panel?
These five steps usually reveal which of the causes below applies to you. If files are missing altogether or the server needs configuration, the work goes to a developer. If you want to close the issue for good rather than just for today, working with a team that offers web design services and sets up an orderly release process from the start removes most of these surprises.
How do you protect your business while the Index of problem lasts?
The technical fix may take a few hours; reducing lost customers in the meantime is up to you. If you run ads in particular, every click lands on a file list instead of your products. So take a few small protective steps first, then return to diagnosis.
- If ads are running, consider pausing them until the problem is fixed.
- Make sure your phone and WhatsApp details are current on your Google Business Profile and social media accounts.
- Tell customers who call that the site is briefly under maintenance; be honest about it.
- If you want to show a temporary page on purpose, serve it with the correct status code; otherwise Google may treat it as content.
These steps do not solve the problem, but they limit damage to reputation and budget during diagnosis. Then work through the causes below in order.
What does the server do when there is no index file?
When someone requests a folder address, the web server first looks for a homepage file with specific names. According to the Apache documentation, the DirectoryIndex directive sets the list of resources to look for when a client requests a directory, and its default is index.html. The same page adds that if none of those resources exist and the Indexes option is on, the server generates its own listing (Apache mod_dir docs).
Nginx works the same way. Its documentation says the index directive defines the files used as an index, checks them in the specified order and defaults to index.html (Nginx index module). In other words, both servers follow the same logic: without a correctly named file, the server either lists the folder or returns an error.
In practice, the most common case looks like this. You reinstall the site and skip the homepage file, or its name starts with a capital letter, such as "Index.html". On Linux servers file names are case sensitive, so "Index.html" and "index.html" are two different files.
Did you upload the site files into the wrong folder?
If the Index of listing shows a single folder name, this is most likely the cause. For example, when you extract a zip archive on the server, the files often land in a subfolder named after the archive instead of the root. A visitor types your domain, the server looks at the root, finds only that subfolder and lists it.
Similarly, some panels create a separate folder for each addon domain. If you upload the site into the main domain folder, the addon domain stays empty. During a new build, a developer may also test in a subfolder. Then on launch day, nobody moves the files to the root.
- Open the subfolder: are the index file and the other site files inside?
- If so, move the contents up one level or point the document root to that subfolder in your panel.
- If you changed folders in a CMS such as WordPress, check the site address setting as well.
- Before moving anything, download a copy of the current files to your computer.
Note: in a CMS, changing folders can also affect addresses stored in the database. If you are not sure, leave this step to a developer.
Why can the DirectoryIndex setting cause an Index of page?
If your files are in the right place and your homepage is index.php, but the server looks only for index.html, you still get an Index of listing. The Apache documentation lists index.html alone as the default. Hosting providers usually extend that list; however, on a custom server or after a configuration reset, the list can shrink.
In Apache, this setting lives in the server configuration or, where allowed, in an .htaccess file. An .htaccess file is a small configuration file that holds server rules for a specific folder. A short example:
DirectoryIndex index.php index.html
This line tells the server to look for index.php first and then index.html. The Apache page also notes that several DirectoryIndex lines in the same context add to the list, and that you can reset it first with the value "disabled". The Nginx equivalent is index index.php index.html;. Because this touches server configuration, leave it to a developer or hosting support if you are unsure.
Is directory listing switched on, and why is that risky?
Directory listing is a server feature that shows visitors the contents of any folder without a homepage. According to the Apache documentation, when the Indexes option of the Options directive is on and a requested directory has no DirectoryIndex file, mod_autoindex returns a formatted listing of the directory (Apache core docs). In Nginx this job belongs to the autoindex module, which the documentation says defaults to off (Nginx autoindex module).
Even if your homepage is fine, subfolders may still expose these lists. For example, the folder holding images, uploads or an old backup becomes a public list. That can reveal who built the site, which plugins it uses or the name of a forgotten backup file to strangers.
Therefore directory listing is not only a display issue; it is an information leak. Files that must stay private should never sit in a public folder in the first place. Still, switching listing off is a cheap first step that keeps them from being easy to discover. If you suspect unauthorized access, follow the first 24 hours in our guide for when your business website got hacked.
How do you turn off directory listing?
The change is a single short line; however, where it goes depends on the server. On an Apache server that allows .htaccess, you can add this line to the .htaccess file in the root folder:
Options -Indexes
The Apache documentation gives an important warning: mixing options that have a plus or minus sign with options that do not is invalid syntax, and the syntax check rejects it at server startup. Also, whether an Options line in .htaccess works depends on the AllowOverride permission in the server configuration. So if the page returns a 500 error after you add the line, remove it and contact hosting support.
Nginx has no .htaccess; the setting lives in the relevant block of the server configuration as autoindex off;. Because the Nginx default is already off, a listing there means someone switched it on deliberately. Take a copy of the current file before any change. Then open the affected folder address in a private window to confirm the list is gone. Seeing a 403 error instead of the list is normal; we explain other causes of that error in our article on ModSecurity and 403 errors.
What happens if the domain points to a new server but the files never moved?
First, this is the most common cause of a default page. You switched the DNS record to the new server, but you have not copied the site files or database there yet. DNS is the system that translates a domain name into a server IP address. A visitor types your domain and reaches the new server. Since no site lives there, they see an empty folder, an Index of listing or the provider landing page.
One more detail makes this confusing: a DNS change does not reach everyone at once. That is because internet providers and devices keep the old record in cache for a while. So one device may show the old site while another shows the empty new server. How long that takes depends on the record settings, so quoting a fixed time would be misleading.
- If the old server is still running, consider pointing the DNS record back to the old IP address for now.
- Copy files and database to the new server, test them and then switch the record again.
- Check how the site looks from different networks.
For a site that loads on some networks but not others, see our dedicated guide; if the domain does not resolve at all, our article on the DNS_PROBE_FINISHED_NXDOMAIN error helps. The right order for a move is in our checklist for changing web hosting without downtime.
Why does a hosting provider welcome page appear?
Hosting providers may show a generic page for domains that point to their servers but are not yet attached to an account or folder. That page often carries the provider logo and a message along the lines of "this domain is not configured yet". Also, when a provider suspends an account or it expires, a different notice page may appear.
In this case the problem is not your files but the link between the domain and the account. Check in your panel whether the domain appears as the main domain, an addon domain or a parked domain. If it does not, ask hosting support to attach it to your account.
If you cannot reach the provider at all, or the company has closed, the situation is urgent. Follow the steps in our guide on what to do when your hosting company is unreachable or closed.
Why did a default page appear after a server update?
Sometimes a site runs fine for months, and then one morning a default test page shows up. This usually follows a server update, a control panel change or a reinstall. A virtual host is the configuration that tells a server which folder to serve for which domain. If someone deletes or disables that entry, the server falls back to its default site.
In this case your files are most likely still in place. What you can do yourself is note when the problem started and the last action taken, then pass that to whoever manages the server. On managed hosting, that is your provider support team; on your own virtual server, it is your developer or system administrator.
Also, backing up configuration files before an update turns a surprise like this into a few minutes of rollback. We listed what to check during routine upkeep in our monthly website maintenance checklist.
What does an Index of listing in a single subfolder mean?
If your homepage loads fine, but clicking a link or typing a folder name brings up a file list, the situation is different. The site is live; however, that folder has no homepage file and directory listing is on. For example, an image folder, an old campaign folder or a test folder a developer forgot can stay public this way.
So a list in one subfolder is a sign of a sitewide setting. If you cover just that folder with an empty file, the other folders stay open. The right step is to switch directory listing off across the site and clean out unneeded folders.
Also, if subpages behave oddly after a move, check hidden files. Files whose names start with a dot, such as .htaccess, may stay hidden by default in some file managers and file transfer tools. As a result, people often skip them during a migration, and redirect rules disappear. Turn on the option to show hidden files and compare the old and new server.
Example scenario: an Index of listing on moving day
Example scenario: an architecture firm moves its website to a new hosting account. An employee downloads a zip backup of the old site, uploads it to the file manager of the new panel and extracts it. Then they switch the DNS record to the new server. The next day a client says that the site shows a single folder name under the heading "Index of /".
A look at the file manager reveals the cause right away: the archive extracted the files into a subfolder named after the backup rather than into the root. The server finds no homepage file in the root and, since directory listing is on, shows that one folder. The fix is to move the subfolder contents up one level and then switch off directory listing.
In another version of the same scenario, the provider landing page appears instead, because nobody attached the domain to the new account. Similar symptom, different cause. In short, the first step is never a guess; you check the file manager and the domain settings.
The lesson: had they tested the site on the new server before switching DNS, the client would never have seen that list. That is why a staging site, or at least a temporary test address, matters before going live.
What can you fix yourself, and when do you need a developer?
To be honest, you can solve a good part of the Index of problem from your panel. The rest needs server configuration, and one wrong line can take the whole site offline.
- Yourself: look for the homepage file in the file manager, move files from a subfolder to the root, fix a capital letter in a file name, check the document root in the panel and compare the IP address in your DNS record.
- Hosting support: attach the domain to your account and check the default page setting on their side.
- Developer: adjust DirectoryIndex and directory listing, repair the virtual host, restore deleted files from backup and update addresses in your CMS.
When you write to a developer, include your domain, a screenshot of what you see, the day the problem started and the last change made. Those four details cut down guesswork considerably.
How do you confirm the problem is really fixed?
Still, your site coming back on your own screen does not mean the job is finished. Your browser or internet provider may still hold an old response in cache, so another visitor could still see the list. That is why you should confirm under different conditions.
- Open the site in a private window and in another browser.
- On your phone, turn off Wi-Fi and try mobile data.
- Type the domain with and without "www" separately.
- Open a known folder address, such as images or uploads; you should see a 403 or a redirect, not a list.
- Submit the contact form once and check that the message arrives.
Then write down what you changed: which folder, which setting, which day. That way, if the problem returns during the next move, you know where to start. Also, that note gives any developer who takes over the site a valuable head start.
What should you do if Google indexed the Index of page?
If the problem lasted a few days, Google may have crawled the directory listing or default page instead of your site. First fix the actual problem so that your homepage shows your content again. Then you can request a recrawl through the URL Inspection tool in Search Console. Google recommends this tool for individual URLs and a sitemap for large numbers of URLs. It also states that requesting a crawl does not guarantee inclusion instantly or even at all (Google recrawl docs).
However, if Google indexed subfolder listings, the approach differs. According to Google, requests made in the Removals tool last for about six months and should go together with a permanent method; removing the content, password protection or noindex are the permanent options. The same page warns against using robots.txt to block a page (Google remove information docs). Check the current duration on that page.
We explained which pages should stay out of the index in our guide on which pages should be noindexed.
What are the most common mistakes with an Index of page?
Most of the mistakes we see happen while someone rushes to close the problem. Then the next update brings it back.
- Dropping in an empty index.html to hide the list; visitors now see a blank page and the real site is still missing.
- Switching DNS before moving the files.
- Not checking the folder structure after extracting a zip archive.
- Editing .htaccess without a backup; one wrong line causes a 500 error.
- Turning off directory listing only in the root and forgetting upload folders.
- Shutting down the old server before everything on the new one checks out.
What these mistakes share is hiding the symptom and leaving the cause. Finding the cause once and writing it down costs far less than living through the same problem on every move.
How should you set up a site so the Index of page never returns?
An Index of listing or default page rarely comes from one mistake; it comes from a messy release process. Picture a setup where people upload files by hand and test on the live site. Nobody documents the settings, so surprises like this are inevitable. A solid setup, on the other hand, follows a few simple rules.
- Every release goes through a test environment or temporary address first.
- A written document states which folder holds the files and what the document root is.
- Directory listing stays off for the whole site.
- You switch DNS only after the site checks out on the new server.
- A current backup of the site and server settings lives somewhere independent of the server.
- A simple uptime monitor checks the homepage regularly.
Applied together, these six rules turn an Index of listing from a crisis into a minor event; even if it happens, you notice it within minutes and roll it back.
What does our web design team do at this point?
At Talha Aslan and team, we build sites with lean custom code instead of bloated themes and plugin piles. Our scope covers correct caching and clean configuration, speed and Core Web Vitals as architectural decisions, SEO foundations and documented code that any other developer can take over. We write no code before you approve the design; you see every page in a staging environment before launch, and the site goes live with analytics and Search Console connected.
This approach targets the root of the problems above: a documented release process, testing before anything goes live and configuration on record. If your current site keeps producing surprises like this during moves or updates and you are considering a rebuild, you can review scope and process on our corporate website design page. Before deciding, we suggest running the five minute check in this guide; often the fix is moving a single folder.



