How to Reindex SharePoint List or Document Library?

Requirement: Reindex List or Document Library in SharePoint.

Reindex feature in SharePoint allows you to force the search service to reindex the list or library, regardless items are changed or not. The full crawl schedule reindexes all items by default (which you can trigger on-demand from the search service application in SharePoint On-premises). But when you use reindex feature in SharePoint, those items are flagged for re-crawl, and they will be crawled during the next incremental or continuous crawl.

How to Reindex a SharePoint List?

If you want to re-crawl a list or document library, follow these steps:

  1. Go to the List or Library Settings.
  2. Click on Advanced Settings.
  3. Scroll down to Reindex section and click on the “Reindex” button (For Lists, You’ll find a button “Reindex List” and for Libraries, “Reindex Document Library”).
    reindex sharepoint document library
  4. Confirm the prompt to reindex document library SharePoint 2016.
    reindex document library sharepoint 2016

All content of your List or Library will be reindexed during the next scheduled crawl.

Reindex SharePoint List using PowerShell

Do you need to reindex a SharePoint list or document library in a scripted way? Here is the PowerShell way to do it.

Add-PSSnapin Microsoft.SharePoint.Powershell -ErrorAction SilentlyContinue

#Site collection URL variable

#Get the Web and List objects
$Web = Get-SPWeb $SiteURL
$List = $web.Lists.TryGetList($ListName)

    [Int] $SearchVersion = 0

    #Get the existing search version number
    If($List.RootFolder.Properties.ContainsKey("vti_searchversion") -eq $True)
        $SearchVersion = $List.RootFolder.Properties["vti_searchversion"]

    #Increment Search version
    #Update the Search version number
    $List.RootFolder.SetProperty("vti_searchversion", $SearchVersion)

    Write-host -f Green "Search Version has been increased to $SearchVersion on $ListName"

Salaudeen Rajack

Salaudeen Rajack - SharePoint Expert with Two decades of SharePoint Experience. Love to Share my knowledge and experience with the SharePoint community, through real-time articles!

3 thoughts on “How to Reindex SharePoint List or Document Library?

Leave a Reply

Your email address will not be published. Required fields are marked *