Sharepoint - Best way to migrate Document Library files to file system

Their are couple of ways to download the documents from SharePoint Document library.

  • Using the Explorer view, you can drag and drop the documents to local directory.
  • UNC mapping to the SharePoint document library and drag/drop documents to a file share. You could refer this blog for details. This is simplest way but it will not display files that exceed the list throttling. You have to connect to different views.

    If you have an Enterprise Portal site with the URL http://mysharepoint.com/Sites/EnterprisePortal

    Aaccess the document libraries in this site through windows explorer through the UNC path \mysharepoint\sites\enterpriseportal

  • Use the powershell script to donwload all documents from library with the same structures. below powershell you have to donwload from one library at once.

```

######################## Start Variables ########################
######################## Varun's Script######################
$destination = "C:\\tools\\Folder"
$webUrl = "<Url of the specific site>"
$listUrl = "<Url of the specific list. This url is complete Url and NOT relative url>"
##############################################################

$web = Get-SPWeb -Identity $webUrl
$list = $web.GetList($listUrl)

function ProcessFolder {
    param($folderUrl)
    $folder = $web.GetFolder($folderUrl)
    foreach ($file in $folder.Files) {
        #Ensure destination directory
        $destinationfolder = $destination + "/" + $folder.Url 
        if (!(Test-Path -path $destinationfolder))
        {
            $dest = New-Item $destinationfolder -type directory 
        }
        #Download file
        $binary = $file.OpenBinary()
        $stream = New-Object System.IO.FileStream($destinationfolder + "/" + $file.Name), Create
        $writer = New-Object System.IO.BinaryWriter($stream)
        $writer.write($binary)
        $writer.Close()
        }
}

#Download root files
ProcessFolder($list.RootFolder.Url)
#Download files in folders
foreach ($folder in $list.Folders) {
    ProcessFolder($folder.Url)
}

```

read the complete instruction about the script here: https://gallery.technet.microsoft.com/office/SharePoint-2010-files-from-11255dc2

Useful Resource: http://sharepointconnoisseur.blogspot.com/2012/03/options-to-export-sharepoint-2010-files.html