Categories
Interior

How to rebuild the search index in windows

If you search for items in Outlook and don’t receive the results that you expect, the indexing of your Microsoft Windows and Microsoft Office system data files (the search catalog) may not be complete.

Symptoms of an incomplete index include the following:

Partial or no search results are returned.

Items that you expect to appear based on your search criteria aren’t displayed.

You can rebuild the search catalog, which restarts the indexing of your data files. The search catalog is a file where all of your Outlook and Microsoft Windows items (data files) are indexed.

In simple terms, it’s a catalog that’s built from terms found in email messages. The catalog is similar to an index for a reference book, but instead of manually searching for the term in the book’s index, you’re search for it electronically by entering the term in a Outlook search box. You simply need to make sure you’ve set the indexing options to begin.

If you’re using Outlook 2007, the body of digitally signed and encrypted email message are never indexed. This is not the case, however, for Outlook 2016, Outlook 2013, and Outlook 2010. The body of digitally signed email messages in those Outlook versions are indexed if they’re signed and encrypted.

The index is made up of folders that you choose. Those choices become the search scope. This is a two-step process. You set the Outlook indexing options, and then you check the search scope.

Set Outlook search options

How to rebuild the search index in windows

On the File tab, choose Options > Search.

Under Sources, click Indexing Options.

Note: In the Indexing Options dialog box, under Index these locations, make sure Microsoft Outlook is an included location. You can click Modify if necessary to change selected locations.

If you find that search results are missing, no longer valid, or incorrect, then the Search Index may not be up to date – in which case, you can manually rebuild the index to force it to update. In this post, we will show you the two ways to rebuild the Search Index if it’s not working as it should, on your Windows 10 device.

How to rebuild Search Index

Windows Search has been significantly improved to limit the number of times the service indexes your files for content that doesn’t have an impact on search experiences and gives you a better experience on Windows 10.

You can rebuild the search index in Windows 10 in two quick and easy ways.

1] Rebuild Search Index via Control Panel

To Rebuild Search Index via Control Panel in Windows 10, do the following:

  • Press Windows key + R to invoke the Run dialog.
  • In the Run dialog box, type control and hit Enter to open Control Panel.
  • From the top right corner of the window, set the View by option to Large icons or Small icons.
  • Click Indexing Options.
  • In the window that opens, click the Advanced button.
  • In the Index Settings tab, click the Rebuild button under Troubleshooting.
  • Click OK on the prompt to confirm.
  • The indexing operation will now commence.
  • Click the Close button when the indexing completes & exit Control Panel

Keep in mind that rebuilding the index might take a long time to complete. At any time, you can click the Pause button to stop rebuilding the index.

2] Rebuild Search Index using Batch (.BAT) file

To Rebuild Search Index using a batch (.bat) file in Windows 10, do the following:

  • Press Windows key + R to invoke the Run dialog.
  • In the Run dialog box, type notepad and hit Enter to open Notepad.
  • Copy and paste either of the code below into the text editor.

OR

  • Save the file to the desktop with a name and append the .bat file extension – eg, SIRebuild.bat and on the Save as type box select All Files.
  • To run the batch file right-click the saved file and select Run as Administrator from the context menu.
  • Click Yes on the UAC prompt to approve. The search index will now start to rebuild in the background.

How long does it take to rebuild search index in Windows 10?

Depending on the number of files you have set to index, the data size, the power of your processor, the Read-Write speed of your disk, etc, it may take anywhere from a couple of hours to a couple of days for the search index to be rebuilt completely.

Date: February 23, 2021 Tags: Search

Related Posts

How to change the Search box text in Windows 10

What is DuckDuckGo Bang and how to use it effectively?

Windows Search Indexing keeps restarting from scratch after reboot

[email protected]

Anand Khanse is the Admin of TheWindowsClub.com, a 10-year Microsoft MVP (2006-16) & a Windows Insider MVP. Please read the entire post & the comments first, create a System Restore Point before making any changes to your system & be careful about any 3rd-party offers while installing freeware.

Primary Sidebar

report this ad

Windows 10 keeps an index of all your searches so that you can get the fastest search results. If you find that you’re getting slow, missing, or incorrect results, then it might be time to delete and rebuild your search index.

TIP : Hard to fix Windows Problems? Repair/Restore Missing Windows OS Files Damaged by Malware with a few clicks

1: Delete and Rebuild from Indexing Options

Press the Windows Key + S and type in indexing and click on Indexing Options. Click on Advanced.

Under Troubleshooting, click on Rebuild.

You will be notified that “Rebuilding the index might take a long time to complete. Some views and search results might be incomplete until rebuilding is finished.”

1: Run Search and Indexing Troubleshooter

The troubleshooters in Windows 10 include fixes for every known problem and are a great place to start. The most significant advantage of running the troubleshooter is that you don’t have to guess.

Click on Start > Settings > Update & Security > Troubleshoot.

Scroll on the right and click on Search and Indexing and then click on Run the troubleshooter.

Click on any of the problems you’re experiencing and click on Next. If you’re not sure, we will use Search, or indexing is slowing down the computer.

3: Run a Batch File

If the steps above didn’t work for some reason or we want to kick it old school, we could always run a batch (bat) file.

Copy and paste the following code in Notepad and save it as Reset_and_Rebuild_Search_Index.bat. Be sure you can view hidden files or folders or your file will be saved as .txt and open in Notepad. Save, right-click and run as administrator.

Reset_and_Rebuild_Search_Index.bat

If you’d prefer not to create your batch file, we have made Delete and Rebuild the Windows 10 Search Index available for download.

If you receive an error code 5, you need to Run as Administrator.

This article provides guidelines for troubleshooting poor Windows Search performance.

Original product version:  Windows 10 – all editions
Original KB number: В 4558579

Summary

This article discusses common performance issues that affect Windows Search and Search indexing.

If you observe general poor performance when you search or when Windows builds a search index, go to Tune the Indexer performance.

If you observe specific error messages, go to Troubleshoot Search errors.

More information

Tune the Indexer performance

The primary factors that affect indexing performance are the number of items indexed and the overall size of the index. These factors are related but separate.

Number of items indexed

On a typical user’s computer, the Indexer indexes fewer than 30,000 items. On a power user’s computer, the Indexer might index up to 300,000 items. If the Indexer indexes more than 400,000 items, you may begin to see performance issues. For more information, go to “[Size of the index database](#size-of-the index-database).”

The Indexer can index up to 1 million items. If the Indexer tries to index beyond that limit, it may fail or cause resource problems on the computer (such as high usage of CPU, memory, or disk space).

By default, the Indexer indexes any Outlook mailboxes on the computer. If a mailbox contains more than 6 million items, the performance of the Indexer may degrade. For more information, go to the “Change Outlook settings” section.

To check the number of indexed items, select Settings > Search > Searching Windows, and then check the value of Indexed items.

How to rebuild the search index in windows

Size of the index database

As the number of indexed items grows beyond 400,000, the index database grows considerably regardless of the size of those items. The size of the items also affects database size. A database that contains either a few large files or a large number of smaller files can affect performance. Both factors together can compound the problem. The Indexer tries to compress the index data. However, this approach becomes less effective as the index database grows.

To check the size of the index database, use the Size on disk property of the Windows.edb file instead of relying on the Size property or the file size that’s listed in Explorer. Because of the compression algorithms that the Indexer uses on sparse ESE and NTFS files, the value that’s listed in Explorer may not be accurate. Additionally, this Size value might include space that was used by or allocated to the file in the past, instead of using the current size.

By default, Windows.edb is located in the C:\ProgramData\Microsoft\Search\Data\Applications\Windows folder. To check the size of the file, follow these steps:

Right-click Windows.edb, and select Properties.

Check the Size on disk value. This property reflects the actual disk space that the database uses.

How to rebuild the search index in windows

Tuning methods

You can use any of several approaches to improve the performance of Search and the Search Indexer.

To make sure that the index reflects your changes, select Settings > Search > Searching Windows > Advanced Search Indexer Settings > Advanced > Rebuild.

Let the Indexer run for up to 24 hours to rebuild the index database.

Exclude folders

You can use this approach to reduce the number of items that are indexed and to reduce the size of the index database. To exclude whole folders from the index, select Settings > Search > Searching Windows > Add an excluded folder. And then select a folder to exclude.

For a more granular method to include or exclude items, open Searching Windows, and select Advanced Search Indexer Settings. In Indexing Options, select Modify, and then select or deselect locations to index.

Change how the Indexer treats specific file types

To control how the indexer treats specific file types, open Indexing Options, and select Advanced > File Types. You can change how the Indexer treats specific file types (identified by file extension) or add and configure new file types.

Defragment the index database

You can use this approach to reclaim empty space within the index database. Open an administrative Command Prompt window, and then run the following commands in the given order: Sc config wsearch start=disable Net stop wsearch EsentUtl.exe /d %AllUsersProfile%\Microsoft\Search\Data\Applications\Windows\Windows.edb Sc config wsearch start=delayed-auto Net start wsearch

For more information about how to defragment the index database, see the following Knowledge Base article:

2952967 Windows.edb larger than expected when a PST file is indexed in Windows

Change Outlook settings

To help reduce the content of an Outlook mailbox, you can change the synchronization window to a shorter time interval than the default interval of one year. For more information, see the following article:

3115009 Update allows administrators to set additional default mail and calendar synchronization windows for new Exchange accounts in Outlook 2016

Troubleshoot Search errors

If the Indexer successfully builds the index database, you see the message Indexing complete on the Windows Search settings page and in Indexing Options.

‎ How to rebuild the search index in windows

If a different message appears, see the following table for more information about the message and how to respond.

Troubleshooting tips to get you back on track

How to rebuild the search index in windows

  • Facebook
  • Twitter
  • LinkedIn

How to rebuild the search index in windows

  • Tweet
  • Share
  • Email

The search tool in Windows 10 has, with different feature updates of the operating system, both increased and decreased its integration with both Cortana and with File Explorer. These often-shifting changes to how search works leads to glitches—some of which present an easy fix.

These instructions apply to all versions of Windows 10.

Causes of Windows 10 Search Problems

When Windows search isn’t working, it’s almost always a simple software problem. The system may just need a restart to get it working again. Other possible causes could be network-related or the search system itself having a service interruption.

How to rebuild the search index in windows

How to Fix Windows 10 Search Problems

You’ll use a lot of the same methods to fix problems with search as other minor errors. Here are some options to try and get the system back to work.

Check your network connectivity. If you aren’t connected to the internet, Windows 10 search won’t work. Before you try anything more serious, make sure your network is functioning properly.

Restart your device. It’s basic advice, but there’s a reason it’s the first port of call for most Windows errors—reboots often work wonders. If you haven’t tried restarting your device, do so now, as a simple reboot of the system flushes memory and disk-cache glitches that adversely affect system performance. It’s better to perform a restart than shut down too, as shutdowns occasionally send your Windows 10 PC into hibernation mode.

Turn Cortana off and on again. Since Cortana is so entwined with Windows 10’s search function, turning it off and on again sometimes corrects Windows 10’s file-search problems.

Run Windows Troubleshooter. Microsoft’s Windows troubleshooter may not be able to fix every problem it comes across, but it can often send you in the right direction to learn more or at least pinpoint what the actual problem might be. The same goes for problems with the Windows 10 search bar not working.

Open the troubleshooter by opening the Start menu and going to Settings > Update and Security > Troubleshoot > Search and Indexing. Click the Run the troubleshooter button to go through the diagnostics.

Verify the Search service is running. It’s possible the Windows Search service itself has been disabled for some reason.

Press Win+R to open the Run window, then type “Services.msc” and press Enter.

When the Services window appears, scroll down the list of services to find Windows Search. If it’s already running, right-click it or tap and hold, then select Restart. Alternatively, if it’s disabled or has a blank Status, right-click or tap and hold, then select Start.

Rebuild the Windows 10 search indexing options. It may be that Windows 10 has forgotten where certain files and folders are. To help it remember, rebuild its indexing options. Start by accessing the Control Panel in Windows 10.

Select Indexing Options from the main menu icons, and then click Advanced. In the Advanced options, Click Rebuild.

The rebuilding process may take a short time to complete depending on the size of your drive and how full it is.

If none of the above tips helped get your Windows 10 search bar working again, try some more advanced Cortana help tips or opt for a full Windows reset.

How to rebuild the search index in windows

Windows Search makes searching for files on your PC a lot faster, but if you find that things slow down when Windows indexes files or that Search isn’t working as expected, there are a few steps you can take.

Speed Up Indexing by Only Including Certain Locations

The best way to trim down the amount of processor time the indexing service uses is by trimming down the number of files being indexed. For example, if you don’t regularly perform searches of files on your C: drive, there’s really no need to be indexing the whole thing. Personally, I love the search function for my main documents folder and the Start Menu, but that’s about it. Why bother indexing everything else?

You can read all about selecting locations in our full guide to choosing which files Windows Search indexes, where you can also learn about selecting what file types get indexed and other advanced options . But in short, to open up indexing options, hit Start, type “indexing,” and then click “Indexing Options.”

How to rebuild the search index in windows

In the “Indexing Options” window, click the “Modify” button.

How to rebuild the search index in windows

And then use the “Indexed Locations” window to select the folder you want included in the index.

How to rebuild the search index in windows

At the very least, you might want to include the Start menu to make it easier to launch programs just by typing their names. The rest is up to you, but most people go ahead and include folders with person files, such as Documents, Pictures, Videos, and so on. If you keep your personal files stored on another drive, note that those files are typically not indexed by default unless you’ve actually moved your personal document folders to that location.

Disable Windows Search Altogether if You Don’t Use It

If you really don’t use Windows Search at all, you can disable indexing completely by turning off the Windows Search service. This will stop the indexing of all files. You’ll still have access to search, of course. It will just take longer since it has to search through your files every time. If you’re thinking of disabling Search because it’s slowing things down, we recommend trimming down what files are getting indexed and seeing if that works for you first.

You should also note that other apps–notably Microsoft Outlook–use Windows Search to allow searching within those apps, so you’ll have to do without fast searching in those, as well.

That said, if you’re planning on using another search app or you just don’t search often and would rather not have the service running, Windows Search is easy to disable. Hit Start, type “services,” and then click the result.

How to rebuild the search index in windows

On the right-hand side of the “Services” window, find the “Windows Search” entry and double-click it.

How to rebuild the search index in windows

In the “Startup type” drop-down menu, select the “Disabled” option. This will prevent Windows Search from loading the next time you start your computer. Click the “Stop” button to go ahead and stop the Windows Search service now. When the service has stopped, click “OK.”

How to rebuild the search index in windows

And that’s it. Windows Search is now disabled, a fact that Windows is happy to remind you about (and offer to fix) when you do perform searches.

How to rebuild the search index in windows

If you want to turn Windows Search back on, all you have to do is return to it in the Services window, change the “Startup type” option back to “Automatic,” and then click Start to start the service back up.

Rebuild the Windows Search Index if You’re Experiencing Problems

If you are encountering problems with searching–unexpectedly slow searches, not finding things that should be indexed, or searches actually crashing–your best bet is to completely rebuild the search index. It will take a while to rebuild, but it’s usually worth it. Before you rebuild the index, though, it may be worth taking the time to trim down your index locations to just what you need to make the indexing process faster.

Open up the “Indexing Options” window by hitting start and typing “Indexing Options,” and then click the “Advanced” button.

How to rebuild the search index in windows

In the “Advanced Options” window, click the “Rebuild” button.

How to rebuild the search index in windows

After that, it’s just a matter of waiting while Windows rebuilds the index from scratch. You can keep using your PC normally, of course, but searching will continue to be spotty until the index is fully rebuilt. Also, Windows tries to do indexing while your PC is not being used, so it may be best to rebuild the index before going to sleep and just leaving your PC on for the night to do its job. You should be back to searching by the morning.

Windows 10 keeps an index of all your searches so that you can get the fastest search results. If you find that you’re getting slow, missing, or incorrect results, then it might be time to delete and rebuild your search index.

TIP : Hard to fix Windows Problems? Repair/Restore Missing Windows OS Files Damaged by Malware with a few clicks

1: Delete and Rebuild from Indexing Options

Press the Windows Key + S and type in indexing and click on Indexing Options. Click on Advanced.

Under Troubleshooting, click on Rebuild.

You will be notified that “Rebuilding the index might take a long time to complete. Some views and search results might be incomplete until rebuilding is finished.”

1: Run Search and Indexing Troubleshooter

The troubleshooters in Windows 10 include fixes for every known problem and are a great place to start. The most significant advantage of running the troubleshooter is that you don’t have to guess.

Click on Start > Settings > Update & Security > Troubleshoot.

Scroll on the right and click on Search and Indexing and then click on Run the troubleshooter.

Click on any of the problems you’re experiencing and click on Next. If you’re not sure, we will use Search, or indexing is slowing down the computer.

3: Run a Batch File

If the steps above didn’t work for some reason or we want to kick it old school, we could always run a batch (bat) file.

Copy and paste the following code in Notepad and save it as Reset_and_Rebuild_Search_Index.bat. Be sure you can view hidden files or folders or your file will be saved as .txt and open in Notepad. Save, right-click and run as administrator.

Reset_and_Rebuild_Search_Index.bat

If you’d prefer not to create your batch file, we have made Delete and Rebuild the Windows 10 Search Index available for download.

If you receive an error code 5, you need to Run as Administrator.

There may be a point in time where you may wish to clear and rebuild the search index catalog on your Microsoft Exchange 2016 Server. This will cause the server to rebuild the search index from scratch.

In my case, for the past month or so Outlook 2019 (Office 365) clients connecting to an on-premise Microsoft Exchange 2016 Server, have been seeing the message “We’re having trouble fetching results from the server…”. The user can click on “Let’s look on your computer instead.” and the search will complete.

When troubleshooting this issue, I tried all of the following:

  • Clearing and rebuilding the Search index on the client computers
  • Deleted the OST files to re-create the local cached copy on the client computers
  • Restarting the Exchange Server
  • Restarting the Client Computers
  • Analyzing the Event Log for any errors (none)

None of the above helped in troubleshooting.

How to rebuild the search index in windowsOutlook: “We’re having trouble fetching results from the server…”

Because of this, I decided to clear and rebuild the Search Index catalog for the mailbox database on the Exchange Server.

To check the status and to see if your index is corrupt, run the following command:

“ContentIndexState” will report as “Corrupt” if it is corrupt, or “Healthy” if it is healthy.

My server reported as healthy, but I still chose to run the instructions below to rebuild the index.

Instructions

To do delete and re-create your Exchange Server Mailbox Database Search Index Catalog, please perform the following instructions.

Please Note: This is only for Exchange servers that are not part of a DAG. Do not perform these steps if your server is part of an Exchange cluster. Always make sure you have a complete backup of your server.

  1. Log on to your Exchange server.
  2. From the Start Menu, expand “Microsoft Exchange Server 2016”, and right-click on “Exchange Management Shell”, and select “Run as Administrator”.
    How to rebuild the search index in windows
  3. Type the following commands to stop required search services.
  4. Open a file browser (you may need Administrative privilege) and navigate to your Exchange mailbox directory.
  5. You’ll see a folder inside of the mailbox folder with a GUID type name with Single at the end. Delete or move this (preferred is move to alternate location). I’ve put an example below.

This is the folder you want to move/delete.

  • Go back to the “Exchange Management Shell”, and run the following commands to start the services.
  • As mentioned above, you can check the status of the rebuild by running the “Get-MailboxDatabaseCopyStatus” command, and looking at the “ContentIndexState” status.
  • That’s it! After running the command, you may notice your server will experience heavy CPU usage due to Exchange rebuilding the search index.

    After rebuilding the search index, I noticed that my Outlook clients were able to successfully search on the server without having to select “Let’s look on your computer instead.”.

    Windows 10 comes with many useful features preinstalled for the users. One of them is the powerful in-built Search, which indexes multiple locations such as Start Menu, user Folder, and offline files in One Drive folder. Although the Search provides advanced functionality, at times, it doesn’t work as it is expected to be. Users might see broken search results or even deleted files while searching for any content. If your default Search option of Windows 10 is not working appropriately, then there could be multiple reasons behind it. If the same thing happens with you, then follow these tips to fix Windows 10 Search indexing issues.

    How To Fix Windows 10 Search indexing issues

    1. Change Windows Search Service Status
    2. Enhanced Search
    3. Rebuild the Search Index
    4. Windows Search Troubleshooter
    5. Use the Indexer Diagnostics App

    1] Change Windows Search Service Status

    How to rebuild the search index in windows

    First of all, it is essential to find out that the Indexing Option is enabled or not. Though Windows 10 doesn’t stop the service automatically still, we should go ahead and check-in services. To do so,

    • Hold the Windows key and press R to open Run box
    • Type services.msc and click on OK
    • The Services windows will open up with the list of all services, scroll down and look for Windows Search
    • Check the status of Windows Search under the Status column, if it Running is then press OK
    • If Windows Search is not running, then click on Restart the Service to enable it.

    You should also Double Click on the Windows Search service and see the service properties. Please ensure that the Startup Type is either Automatic or Automatic (Delayed Start). Most of the time, this issue related to the Search Index gets resolved by Stopping and Restarting the service. In case if they don’t, you can follow the further steps given below.

    2] Enhanced Search

    How to rebuild the search index in windows

    Enhanced Search in Windows 10 PC will make sure the search is done across the computer, including desktop and libraries. You can configure to exclude some folders, and choose to reduce indexing activity when on battery.

    • Open Windows Settings (Win + I)
    • Go to Search > Searching Windows
    • Switch Find My Files to Enhanced
    • Turn on Index performance when on battery

    If you are unable to find files in Search, then switching to this mode will expand the search index to find files into other drives as well.

    2] Rebuild the Search Index in Windows 10

    Rebuilding the search index is a simple yet time-consuming process. It may take a few hours, depending on the various factors. It is advisable to use this method on a day when you are free and don’t have any other important task scheduled.

    First of all, you need to launch the indexing option, the easiest way to do so is by typing Indexing Option in the Start Menu Search Bar and choose the result. However, if the search option is not working correctly, then you can use the alternative option.

    How to rebuild the search index in windows

    • Right-click on the Start Button and select Control Panel from the list
    • On Control Panel Window, change the view by Category to Small icon.
    • Find and click on Indexing Option from the list of all items.
    • The Indexing Option Window will open up, click on Advanced Button at the bottom.
    • On Advance Option Window select Index Settings tab
    • Click on the Rebuild button, which is located under the Troubleshooting section.

    A confirmation message stating, “Rebuilding the index might take a long time to complete. Some views and search results might be incomplete until rebuilding is finished message” will pop up, click OK.

    How to rebuild the search index in windows

    After this, the rebuild process will be started, which may eventually take a few hours. However, we have seen on several occasions that in personal computers at home, it doesn’t take much time to complete the process.

    3] Utilize the search Troubleshooter to Repair Windows Search

    How to rebuild the search index in windows

    Alike the previous versions, Windows 10 also comes with many in-built troubleshooters that can rectify and fix the problem automatically. One of these is the Search and Indexing troubleshooter that can be accessed and used from the Control Panel.

    • Open Windows Settings using Win + I
    • Navigate to Update & Security > Troubleshoot
    • Locate Search and Indexing troubleshooter.
    • Click on the button and follow the instructions to fix the problem.

    The troubleshooter will detect and fix the issue automatically.

    4] Use Indexer Diagnostics App

    How to rebuild the search index in windows

    Microsoft has rolled out an incredible app for Windows 10 users. Indexer Diagnostics App can help you find out the issue with indexing on Windows 10. It also offers solutions to restart services, checks the status of the file in the index, and more. Here is the list of features:

    • Service Status with the option to sort index usage by last hour, last day, or last week
    • If the Search is not working, you can restart, reset, and also file a bug
    • Check file index status
    • Included and excluded paths
    • Performance measurement
    • Search roots

    It offers many tools to check for problems that Windows Search faces often. If the CPU usage is high because of it or if it is not working, then the tool can help fix it. Download from Microsoft Store

    I hope these tips helped you to fix Windows 10 Search indexing issues, and you were able to find the file on the computer.