SUBMIT A FILE TYPE CONTACT US SUPPORT ABOUT US

How to Convert EDB to PST Four Ways, and How to Check the PST File You Get

An EDB file becomes a PST file one mailbox at a time. Jump to your question below, or work through it in order.

30 min read Updated October 2026 Sources and tests checked

What Does It Mean to Convert EDB to PST? One mailbox makes one PST file

Short answer

To convert EDB to PST, export every mailbox to its own Outlook file. Exchange does it with New-MailboxExportRequest on version 2010 and later, and with Export-Mailbox on version 2007. An offline EDB to PST converter does it when only the EDB file is left.

Native EDB to PST export needs your server up with the database mounted. A dismounted file goes through a recovery database first, and an offline converter skips the server. Microsoft documents the first three ways, and the converter pages are vendor claims that we did not test.

We tested the result of EDB to PST conversion. We read one genuine PST file with two free readers, damaged 17 copies and wrote a script that checks the header and all 8,792 blocks. Use it on any PST that a conversion gives you.

Converting EDB to PST means copying mailboxes out of an Exchange database and into Outlook data files. One mailbox makes one PST file, so an EDB file with 200 mailboxes needs 200 exports.

An EDB file is the database that Exchange Server keeps its mailboxes in. A PST file is the format that Outlook opens. The two have different layouts, so renaming one does nothing. An EDB to PST converter has to read the mail out of the database and write it into a new file.

People convert EDB to PST for four reasons. They need one mailbox for lawyers, audits or former employees. They move mail to Outlook or to other services. They want a backup that needs no server. Or the server is gone and only the EDB file is left.

What goes into an EDB to PST export

What an EDB to PST export reads and writes
You start with You get and why
A private mailbox One PST file for that mailbox. The cmdlet takes one mailbox and one file path. Source: Microsoft.
An archive mailbox A separate PST file. You add -IsArchive to the export. Source: Microsoft.
Recoverable Items Included by default. -ExcludeDumpster leaves them out. Source: Microsoft.
Public folders The 2007 cmdlet cannot export from a public folder database. The 2010 cmdlet exports a primary mailbox or an archive. Source: Microsoft.

In EDB to PST conversion the number of files matters more than the size. A mailbox store with many users gives many PST files, so plan a share with room for all of them. The limits section lists how large one file can grow.

PST files copy mail and are no backup. The tables, the logs and the state of the EDB file stay behind. Keep the EDB file until every EDB to PST result passes the checks on this page.

What Should You Know Before You Convert EDB to PST? Four answers choose how to convert EDB to PST

Four answers choose your way to convert EDB to PST. Is the database mounted, which Exchange version made it, how many mailboxes it has and whether you still have a server. Answer them before you copy anything.

Start with the state. A database that mounts can go through EDB to PST export in Exchange itself. A dismounted one needs its log files first, and the header check on our EDB page shows in seconds whether it closed the right way.

Is the database mounted? Mounted means the server can convert it to PST now. Dismounted means a recovery database or an offline converter.
Which version made it? The version names the cmdlet for EDB to PST export. The table below lists five cases and where every one stops.
How many mailboxes? One mailbox is one EDB to PST export. Hundreds need a loop, a big share and a failure plan.
Do you have a server? Native EDB to PST export needs Exchange up. Without it, only an offline converter can read the EDB file.

Which EDB to PST tool belongs to which version

Exchange versions and their PST export tools
Version Tool and source
Exchange 2010 to SE New-MailboxExportRequest, which needs a running server and a mailbox. Microsoft lists Exchange 2010, 2013, 2016, 2019 and SE. Source: Microsoft.
Exchange 2007 SP1 to SP3 Export-Mailbox with -PSTFolderPath. It needs a 32 bit computer with Outlook. Source: Microsoft archive.
Exchange 2007 RTM No export to PST. Microsoft names two workarounds, export with Outlook or export to a mailbox and then use Outlook. Source: Microsoft archive.
Exchange 2003 and 2000 The 2007 cmdlet reads mailboxes on 2003 SP2 and 2000 SP3 or later. ExMerge is on Microsoft's replaced or removed list. Source: Microsoft archive.
Exchange Online Not applicable. Microsoft says New-MailboxExportRequest is available only in on premises Exchange. Source: Microsoft.

Exchange 2007 reached the end of its support on 11 April 2017, as the archived Microsoft page says. Old EDB files from Exchange 2007 are still around, so the 2007 steps for EDB to PST stay on this page.

Work on copies. Copy the EDB file and every log to a safe folder before any EDB to PST step. Our EDB page lists what to check first.

Which Way Should You Use to Convert EDB to PST? Four ways, by what you have in your hands

Convert EDB to PST through Exchange when the server is up and the database is mounted. Use a recovery database when the file is dismounted but the server is there. Use an offline converter when you only have the EDB file.

A decision flow with three questions that lead to four ways to convert EDB to PST. Question 1 asks if an Exchange server is running with the database mounted. If yes, use New-MailboxExportRequest on Exchange 2010 and later, or Export-Mailbox on Exchange 2007 SP1 and later. If no, question 2 asks if a server can mount a copy of the EDB file. If yes, make a recovery database, restore the mailbox and export it. If no, or if the file is damaged, use an offline converter. Every path ends with a check of the PST file.
Three questions choose your way to convert EDB to PST. A damaged file always ends at an offline converter.
Four ways to convert EDB to PST
Way What it needs
Way 1. EDB to PST with Export-Mailbox Needs Exchange 2007 SP1 or later, a 32 bit computer and Outlook. Best when the old server still starts. Source: Microsoft archive.
Way 2. EDB to PST with New-MailboxExportRequest Needs Exchange 2010 or later, a mounted database, a role and a share. Best when the server starts and the database is mounted. Source: Microsoft.
Way 3. EDB to PST with a recovery database Needs a server, the EDB file and its logs. Best when the database is dismounted but a server is there. Source: Microsoft.
Way 4. EDB to PST with an offline converter Needs Windows and the EDB file. Best when no server is left or the EDB file is damaged. Source: Vendor pages.

Microsoft documents ways 1 to 3 of converting EDB to PST. Ways 1 and 2 are exports from a mailbox, and way 3 is a restore followed by an export. We could not test any of the three, because we had no Exchange server. Way 4 rests on two vendor pages that we read and did not use.

A short rule for choosing how to convert EDB to PST

Ask what you have in your hands before you convert EDB to PST. Live servers point to ways 1 and 2. Servers with dismounted files point to way 3. Only the file points to way 4. Damaged files point to way 4 too, because native export needs databases that mount.

How Do You Convert EDB to PST With PowerShell? New-MailboxExportRequest on Exchange 2010 and later

Convert EDB to PST on Exchange 2010 and later with New-MailboxExportRequest. Give your account the right role, make a share, start the request, watch it and check the PST file.

This is the way Microsoft documents to convert EDB to PST from mounted databases. The cmdlet page says it exports primary mailboxes or archives to PST files, and that it works only in on premises Exchange. Microsoft's export guide walks through the same steps for Exchange 2016 and 2019.

A five step chain for one export on Exchange 2010 and later. A mounted database contains the mailbox. Your account needs the Mailbox Import Export role. The export request starts and Exchange writes the file. The PST file lands on a network share that the Exchange Trusted Subsystem group can write to. Last, you check the file with item counts, its size and a script.
One EDB to PST export on Exchange 2010 and later. The check at the end is yours, because Exchange does not make it.
  1. Give your account the Mailbox Import Export role. Microsoft says no role group has it by default, so add it to the Organization Management group.
  2. Make a folder on your network share for EDB to PST files. Give the Exchange Trusted Subsystem group read and write permission on it. Without that permission Exchange cannot reach the PST file.
  3. Start the EDB to PST export with the mailbox name and the share path.
  4. Watch the request with Get-MailboxExportRequest until it ends.
  5. Check the PST file before you remove anything. The check section lists the steps.
  6. Remove finished requests with Remove-MailboxExportRequest. Exchange names up to 10 requests for a mailbox by itself, so add -Name when you need more.
Step 1. Add the role
New-ManagementRoleAssignment -Role "Mailbox Import Export" -User Administrator
Step 3. Export one mailbox to PST
New-MailboxExportRequest -Mailbox AylaKol -FilePath "\\SERVER01\PSTFileShare\Ayla_Recovered.pst"

The first line gives your account the role. The second line is the example from Microsoft's page, and it writes the mailbox AylaKol to a PST file on the share. The path must start with two backslashes and a server name, because the file is written by the Exchange service and not by your session.

Options that change the EDB to PST export

Options of the export cmdlet
Need Option and what it does
Archive -IsArchive exports the archive mailbox and not the primary mailbox. Source: Microsoft.
Folders -IncludeFolders lists the folders to export. #Inbox# names the Inbox in any language. -ExcludeFolders leaves folders out. Source: Microsoft.
Filter -ContentFilter exports only matching items, with OPATH syntax. You can export from a date or to a date, but not between two dates. Source: Microsoft.
Bad items -BadItemLimit sets how many corrupt or missing items are allowed before the request fails. The default is 0, and Microsoft suggests 10 or lower. Source: Microsoft.
Dumpster -ExcludeDumpster leaves out the Recoverable Items folder, which is exported by default. Source: Microsoft.
Top folder -TargetRootFolder sets the top folder inside the PST file. Without it, the content goes to the top of the PST file. Source: Microsoft.

On Exchange 2010, a -BadItemLimit of 51 or higher also needs the -AcceptLargeDataLoss switch. Later versions ask for it when -LargeItemLimit is 51 or higher, as Microsoft's page says.

Convert many EDB mailboxes to PST in one go

One request makes one PST file. To convert EDB to PST for every mailbox in a database, loop over the mailboxes and name the files after their aliases. This loop is ours. We built it from the documented options and could not use it, so try it on two test mailboxes first.

Our loop, not tested
Get-Mailbox -Database DB1 | ForEach-Object {
    New-MailboxExportRequest -Mailbox $_.Alias -FilePath "\\SERVER01\PSTFileShare\$($_.Alias).pst"
}

When an EDB to PST request stops

The default for -BadItemLimit is 0, so one corrupt item fails the EDB to PST request. Microsoft suggests 10 or lower when you accept leaving few items behind. A failed EDB to PST request stays in the list until you remove it with Remove-MailboxExportRequest.

We could not test these commands. We had no Exchange server, so every EDB to PST command in this section comes from Microsoft's pages. Check the syntax against the page for your version before you use it.

How Do You Convert EDB to PST on Exchange 2007? Export-Mailbox for EDB to PST, with a 32 bit computer and Outlook

Convert EDB to PST on Exchange 2007 with Export-Mailbox. It needs Service Pack 1 or later, a 32 bit computer with Outlook and full access to the mailbox.

Microsoft's archived export page covers EDB to PST export on Exchange 2007 SP1 through SP3. The PST option came with Service Pack 1, as Microsoft's export steps page shows. The version table above lists the workarounds for the first release.

  1. Use a 32 bit computer that has the 32 bit Exchange management tools and Outlook 2003 SP2 or later.
  2. Make your account an Exchange Server Administrator and a local administrator on the server, and give it full access to the source mailbox.
  3. Convert the EDB mailbox to PST with -PSTFolderPath, using the full path and file name.
  4. For many mailboxes, pipe Get-Mailbox into the cmdlet. Exchange saves one PST file for every alias.

Microsoft says to grant full access before EDB to PST export, with Add-MailboxPermission and the FullAccess right. The next line is our example of that, and we did not try it.

Grant full access, our example
Add-MailboxPermission -Identity john -User Admin01 -AccessRights FullAccess
Export one mailbox
Export-Mailbox -Identity john@contoso.com -PSTFolderPath C:\PSTFiles\john.pst
Export an organizational unit
Get-Mailbox -OrganizationalUnit Marketing | Export-Mailbox -PSTFolderPath C:\PSTFiles -RecipientKeywords "tony@fabrikam.com","christine@fabrikam.com"

The last two lines come from Microsoft's page. The second converts the unit's mailboxes to PST, with one file for every mailbox, named after its alias. It exports only the messages whose recipients include one of the two addresses.

What EDB to PST export on 2007 cannot do

No recovery storage group Exchange cannot export to PST from mailboxes in recovery storage groups. Restore the mail into a spare mailbox first.
No public folder database You cannot export data from a public folder database.
Rules stay behind Associated messages, which store rules, views and forms, are left out unless you add -IncludeAssociatedMessages.
Dumpster items change Dumpster items come out as regular items in the PST file.

What about ExMerge?

Old guides for EDB to PST conversion still show ExMerge screens. Microsoft's list of changed features for Exchange 2007 puts the Mailbox Merge Wizard under replaced or removed features and points to Export-Mailbox and the Move Mailbox Wizard instead. If a guide shows ExMerge, check which version it was written for before you follow it.

Exchange 2007 is long past its support. Microsoft ended support on 11 April 2017. Use these steps to convert EDB to PST, and plan to leave the platform.

How Do You Convert a Dismounted EDB File to PST? A recovery database first, then EDB to PST export

Convert a dismounted EDB file to PST through a recovery database. Restore one mailbox from it into a spare mailbox, then export that mailbox to PST with the cmdlets above.

Microsoft's recovery database guide shows how to mount a copy of an EDB file next to the live databases and restore mailbox data from it. The guide ends with New-MailboxRestoreRequest, and the export cmdlet starts from a mailbox. The two steps join into an EDB to PST route, and that is our reading. We did not test the chain.

  1. Copy the EDB file and its logs to a folder on the server. The EDB state check shows how to read the state first.
  2. If the state reads DirtyShutdown, replay the logs on the copy with Eseutil /R, as Microsoft describes.
  3. Make a recovery database that points at the copy, restart the information store service and mount it.
  4. List its mailboxes with Get-MailboxStatistics, and restore the one you need into a spare mailbox with New-MailboxRestoreRequest.
  5. Export the spare mailbox to PST with New-MailboxExportRequest, then remove the spare mailbox.

The recovery database keeps your live mail safe while you convert EDB to PST, because it lives beside the live databases and stays apart from them. The commands for steps 2 to 4 are on our EDB page, with the paths and names for one test case.

EDB to PST in a recovery storage group on Exchange 2007

Exchange 2007 has a recovery storage group in place of a recovery database. Microsoft says you cannot export to PST from a mailbox in one. So the mail has to reach your live mailbox before the EDB to PST export. That is our reading of the limit, and we did not test it.

Restore needs the server and its license. This way needs a working Exchange server of the version that can mount the file. If you have none, the next section covers offline EDB to PST conversion.

How Do You Convert EDB to PST Without Exchange? Offline EDB to PST converters, and how to test one

Convert EDB to PST without Exchange with an offline converter. SysTools and Freeviewer both list one that reads the EDB file and saves PST files. We read their pages and did not use either one.

An offline EDB to PST converter reads the EDB file itself, so it needs no server and no mounted database. It also reads damaged files, according to both vendors. That makes it the only way for a file with no server behind it.

SysTools EDB to PST Converter

Saves EDB files to PST, EML, MBOX, MSG and more, with or without Exchange

Windows converter

Freeviewer EDB to PST

Saves EDB files, damaged ones too, to PST, EML, EMLX, MSG, MBOX and more

Windows converter

What two EDB to PST converter pages say

What two EDB to PST converter pages say
Topic What the pages say
Output formats Both pages list PST, EML, EMLX, MSG, MBOX, HTML, PDF, DOC, DOCX, CSV, TXT, ICS, MHT, JSON and vCard. SysTools says PST is Unicode by default.
Exchange versions SysTools lists 2003 to 2022 in its specifications and 2000 to 2016 in its FAQ. Freeviewer lists 2003 to 2019, and its FAQ mentions 2000.
Damaged files Both pages offer a Quick scan and an Advanced scan for corrupt EDB files.
Free version Both demos save 25 items per folder, and the Freeviewer demo previews recovered data as well. The SysTools FAQ says 25 items per mailbox.
Server and Outlook SysTools says no live server is needed and Outlook is optional, though its Use Outlook option wants a configured POP3 profile. Freeviewer does not say if Outlook or Exchange must be installed.
System Both list Windows 7 to 11, .NET Framework 4.5, about 100 MB of disk space and 4 GB of RAM as recommended. SysTools adds Windows Server 2008 to 2022, and Freeviewer lists Windows Server 2003 to 2016.

These are vendor claims about EDB to PST conversion. The two pages overlap, but their lists of versions differ, and the SysTools page does not match itself. Ask which Exchange versions your file needs before you pay for a license.

How to test an EDB to PST converter before you trust it

  1. Work on a copy of the EDB file and keep the original.
  2. Open the copy in the free version and read the folder tree that it shows.
  3. Convert one mailbox to PST. The free versions save 25 items per folder, which is enough to see the structure.
  4. Open the PST in Outlook and compare the folders with the preview.
  5. Use the PST check on the file before you buy anything.

Freeviewer also has an EDB recovery page for damaged files that need EDB to PST conversion. We did not test it, and its demo stops at 25 items per folder as well.

Do not upload an EDB file to an online converter. An EDB file can store the mail of many people. Use an EDB to PST program that works on your own computer.

What Does Our Expert Say About Converting EDB Files? A note from Neeraj Singh on counting first

Count the mailboxes, choose your way to convert EDB to PST and check every PST you make. A PST that opens is not proof that it is sound. That is the main lesson from our tests.

Neeraj Singh

Expert insight

“Use Exchange to convert EDB to PST when the database is mounted and a server is up. When you have only an EDB file, count the mailboxes first and then choose your way. A PST that opens is not proof that it is sound, so count the items and check the file before you delete the original.”

Neeraj Singh Manager, Tech Support & Operations 19+ years fixing Windows and system errors

Why opening is not enough

Free readers open damaged PST files from EDB to PST work and say nothing. In our tests libpff and libpst both read a PST after changed size fields, flipped bytes and cut tails with no warning. The study section shows all 17 cases.

An EDB to PST converter can fail in the same quiet way. PST files that are short by a few items still open in Outlook. Only counts against the source, and checks of the file itself, show the gap.

Keep the original until you sign off. Delete nothing from the source until the item counts match and a second person has opened the EDB to PST results.

What Did We Learn From 17 Damaged PST Files? Free readers opened 8 of them with no warning

We read one genuine 57 MiB PST file and made 17 damaged copies. Our script flagged 15 of them. Two free readers opened 8 copies with no error, and one of them returned different mail for 2 copies. A PST file that opens is not proof of a sound file.

We had no Exchange server, so we could not test EDB to PST conversion itself. We tested the half that reaches you, the PST file. We took one genuine file from the public test data of the plaso project. It is 59,442,176 bytes in the Unicode format. Libpff found 544 messages in 29 folders.

Two free readers opened it. Libpff, through its Python module pypff, counted 544 messages. Libpst, with its readpst program, wrote 539. The counts differ by 5 and we did not chase the gap, so compare counts from one reader only. Our script found 846 pages in the two trees and 8,792 data blocks, and every one passed.

Then we made 17 damaged copies, with one change in every copy. We changed the header, the two trees, a data block and the length of the file. We tested all of them with both readers, the file command and our script.

17 damaged copies made
15 of 17 copies flagged by our script
8 of 17 copies that both readers opened with no error
2 of 17 copies where libpff returned different mail
What four checks did with 17 damaged PST copies
Check Result
The file command Named 16 of 17 copies as Outlook files, even the one cut to 100 bytes. It printed only data when we zeroed the signature.
libpff 20260926 Opened 9 copies and refused 8. Seven of the 9 gave our original counts and digest. Two gave different mail.
libpst 0.6.76 Opened 10 copies and refused 7. All 10 wrote 539 messages, the same as the original.
Our script Flagged 15 copies and passed 2. Our script section shows the code.
A grid of seventeen kinds of damage made on one 57 MiB PST file with 544 messages, against three checks. Amber means a pass with no warning and red means the reader returned different mail with no warning. Both libpff and libpst opened eight of the copies with no error. libpff returned different mail for two copies. Our script flagged fifteen copies and passed two, one with the encoding setting changed and one cut with its size field fixed.
Seventeen kinds of damage we made in one PST file to test checks for EDB to PST results. Amber means no warning, and red means different mail with no warning.

Where the readers and the script split

Damage in the header split the readers. A flipped header checksum stopped libpff and not libpst. A zeroed encoding setting stopped libpst and not libpff. Both refused a zeroed signature, a version of 99 and a moved tree pointer.

Damage in the middle of the file slipped past both. Flipped bytes in the block tree or in data blocks and the raised size field all opened with no error. A flipped byte in the node tree and 4 KB of zeros changed the mail that libpff returned, and nothing said so.

The length of the file mattered little. Copies without their last 1 MiB, copies with 1 KB of zeros added and copies with wrong size fields all opened. Our script flagged all three. Cutting the file in half stopped both readers.

What the script cannot see

A changed encoding setting The checksums cover the bytes as stored, so the script passed this copy. It prints the setting, but it does not judge it. Libpst refused the copy.
A cut with a fixed size field We cut off 1 MiB and fixed the size field and both header checksums. The script passed it, and both readers gave the original mail. The cut took nothing that they needed.
Mail that never arrived The script checks the file. It cannot know how many items the mailbox had, so only a count against the source finds missing mail.
Other formats The script reads Unicode files with 512 byte pages. It stops with a note on older ANSI files and on the newer 4096 byte format.

Read the study with care. All 17 copies come from one PST file. We used no Exchange server, no converter and no Outlook. We tested no ANSI file and no file near the size limits. The study shows what can happen. It does not show how common any case is.

How Do You Check a PST File After You Convert EDB to PST? Count the items, then check the file itself

Check every PST file after you convert EDB to PST, in three steps. Compare item counts with the source. Compare the file size and the folders in Outlook. Then use our script on the file. The counts find lost mail, and the script finds damage that readers pass.

An EDB to PST tool says it finished. That is not a check. Do the steps below on every PST file, and keep the EDB file until all of them pass.

  1. Write down the item count of every source mailbox before you convert EDB to PST.
  2. After the EDB to PST export, read the statistics of the request and compare the items it moved with your count.
  3. Look at the size of the PST file. Files of a few KB for large mailboxes failed.
  4. Open the PST file in Outlook and compare the item count of a few big folders with the source.
  5. Use our script on the file.
  6. Ask a second person to open the PST file, then remove the source.
Count before, read the request after. Our commands, not tested
Get-MailboxStatistics -Identity AylaKol | Format-List ItemCount, TotalItemSize
Get-MailboxExportRequest -Mailbox AylaKol | Get-MailboxExportRequestStatistics | Format-List *

Microsoft's pages for Get-MailboxStatistics and for the export request statistics do not list their output fields. The first line names two fields that we expect. On the second line, Format-List * shows all of them, so look for the items moved and the bad items.

What every check finds
Check What it shows
Item counts Finds mail that never reached the file, like bad items that Exchange skipped. Misses damage that keeps the count.
File size Finds an empty or tiny file. A mailbox and its PST file are counted in different ways, so the sizes do not need to match.
Open in Outlook Finds a file that Outlook refuses. Two free readers opened 8 damaged copies, so a file that opens proves little.
Our script Finds changed headers, bad pages and bad blocks. It flagged 15 of 17 copies. It misses changed encoding settings and harmless cuts.

Use our script on the PST file

Use the script on every EDB to PST result. It reads the Unicode header and checks both header checksums. It also checks that the size field matches the file.

Then it follows the roots of the node tree and the block tree and checks every page trailer. It checks the trailer of every data block that the block tree lists. It is 85 lines of Python, needs no extra modules and changes nothing.

check_pst.py
import os, struct, sys, zlib

VER = {14: 'ANSI', 15: 'ANSI', 21: 'ANSI', 23: 'Unicode', 36: 'Unicode, 4096 byte pages'}


def crc(b):
    return zlib.crc32(b, 0xFFFFFFFF) ^ 0xFFFFFFFF


def sig(ib, bid):
    x = (ib ^ bid) & 0xFFFFFFFF
    return (x & 0xFFFF) ^ (x >> 16)


def walk(data, root, size, seen, leaves, bad):
    """Visit every page below a B-tree root, check its trailer, collect leaf pages."""
    stack = [root]
    while stack:
        ib = stack.pop()
        if ib in seen:
            continue
        seen.add(ib)
        if ib % 512 or ib < 0x4400 or ib + 512 > size:
            bad.append(('pointer', ib))
            continue
        pg = data[ib:ib + 512]
        ws, cr, bid = struct.unpack_from('<HIQ', pg, 498)
        if pg[496] not in (0x80, 0x81) or pg[496] != pg[497] or ws != sig(ib, bid) or crc(pg[:496]) != cr:
            bad.append(('page', ib))
            continue
        cent, cb, lvl = pg[488], pg[490], pg[491]
        if lvl:
            for i in range(cent):
                stack.append(struct.unpack_from('<Q', pg, i * cb + 16)[0])
        else:
            leaves.append((pg[496], cent, cb, ib))


def check(path):
    size = os.path.getsize(path)
    data = open(path, 'rb').read()
    print('file        ', path, '(%d bytes)' % size)
    if len(data) < 564:
        print('problem      only %d bytes, the header needs 564' % len(data))
        return
    ok = data[:4] == b'!BDN'
    print('signature   ', data[:4].hex(' '), 'OK' if ok else 'WRONG, expected 21 42 44 4e')
    if not ok:
        return
    ver, = struct.unpack_from('<H', data, 10)
    print('version     ', ver, VER.get(ver, 'UNKNOWN'))
    if ver != 23:
        print('rest        skipped, this script checks Unicode files with 512 byte pages only')
        return
    for name, at, span in (('crc partial', 4, 471), ('crc full', 524, 516)):
        stored, = struct.unpack_from('<I', data, at)
        calc = crc(data[8:8 + span])
        print(name.ljust(12), '%08x' % stored, 'OK' if stored == calc else 'WRONG, computed %08x' % calc)
    eof, = struct.unpack_from('<Q', data, 184)
    print('file size   ', eof, 'OK' if eof == size else 'WRONG, the file has %d bytes' % size)
    print('crypt method', data[513], {0: 'none', 1: 'permute', 2: 'cyclic'}.get(data[513], 'UNKNOWN'))
    seen, leaves, bad = set(), [], []
    for name, at in (('NBT', 224), ('BBT', 240)):
        walk(data, struct.unpack_from('<Q', data, at)[0], size, seen, leaves, bad)
    print('tree pages  ', '%d visited, %d bad' % (len(seen), len(bad)), bad[:3] if bad else '')
    blocks = badb = 0
    for ptype, cent, cb, ib in leaves:
        if ptype != 0x80:
            continue
        for i in range(cent):
            bid, bib, n = struct.unpack_from('<QQH', data, ib + i * cb)
            blocks += 1
            end = bib + (n + 16 + 63) // 64 * 64
            if end > size:
                badb += 1
                continue
            tn, ws, cr, tbid = struct.unpack_from('<HHIQ', data, end - 16)
            if tn != n or tbid != bid or ws != sig(bib, bid) or crc(data[bib:bib + n]) != cr:
                badb += 1
    print('data blocks ', '%d listed, %d bad' % (blocks, badb))


for p in sys.argv[1:]:
    check(p)
    print()

Start it with python3 check_pst.py mailbox.pst. It prints one line for every check. This is what it printed for our genuine file.

The script on a good PST file
file         mailbox.pst (59442176 bytes)
signature    21 42 44 4e OK
version      23 Unicode
crc partial  1ec28790 OK
crc full     0c6726ee OK
file size    59442176 OK
crypt method 1 permute
tree pages   846 visited, 0 bad
data blocks  8792 listed, 0 bad
A map of what our PST script checks, from the file header to the data blocks. The header has the signature, two checksums, the version, the size field, the encoding setting and the roots of two trees. The script follows the roots through 846 tree pages of 512 bytes, checks the trailer of every page, and then checks all 8,792 data blocks listed in the block tree. It cannot see items that were never exported.
What our script reads in your EDB to PST result, from the header to the last data block. The numbers come from our test file.

The next two listings are copies that both readers opened with no error. The first has one flipped byte in a data block. The second lost its last 1 MiB, so the size field and the file disagree by 1,048,576 bytes.

One flipped byte in a data block
file         mailbox-copy-flipped.pst (59442176 bytes)
signature    21 42 44 4e OK
version      23 Unicode
crc partial  1ec28790 OK
crc full     0c6726ee OK
file size    59442176 OK
crypt method 1 permute
tree pages   846 visited, 0 bad
data blocks  8792 listed, 1 bad
A copy that lost its last 1 MiB
file         mailbox-cut.pst (58393600 bytes)
signature    21 42 44 4e OK
version      23 Unicode
crc partial  1ec28790 OK
crc full     0c6726ee OK
file size    59442176 WRONG, the file has 58393600 bytes
crypt method 1 permute
tree pages   846 visited, 0 bad
data blocks  8792 listed, 0 bad

Count the items after EDB to PST conversion with a free reader

A free reader counts the mail without Outlook. Install it with pip install libpff-python. This script adds up the messages in every folder.

Count the messages in a PST file
import pypff

def count(folder):
    n = folder.get_number_of_sub_messages()
    for i in range(folder.get_number_of_sub_folders()):
        n += count(folder.get_sub_folder(i))
    return n

pst = pypff.file()
pst.open("mailbox.pst")
print(count(pst.get_root_folder()), "messages")
pst.close()

It printed 544 for our genuine file. It printed 544 again for the copy with a flipped data byte and for the copy that lost 1 MiB. So a count alone missed two copies that our script flagged, and the script alone cannot see mail that never arrived. Use both.

A pass is not proof. A good EDB to PST result means the parts we checked match their checksums. It does not mean every mailbox is in it. Only counts against the source show that.

How Large Can a PST File Get? Plan the size before you convert EDB to PST

A Unicode PST file stops at 50 GB by default in Outlook 2010 and later, and at 20 GB in Outlook 2003 and 2007. An old ANSI file stops near 2 GB. One big mailbox can pass that, so plan to split your EDB to PST export.

Every EDB to PST export must fit these limits. Microsoft's page on Outlook data file limits lists the defaults in the table below. Microsoft says you can raise the Unicode limits, but it does not recommend it, because performance can drop.

Default size limits of PST files
Format Limit and source
Unicode, Outlook 2010 and later The default maximum is 50 GB, with a warning at 47.5 GB. Source: Microsoft.
Unicode, Outlook 2003 and 2007 The default maximum is 20 GB, with a warning at 19 GB. Source: Microsoft.
ANSI, the older format The default maximum is 1.933 GB. Microsoft says the value is ignored above 2 GB, to prevent corruption. Source: Microsoft.

Our script reads the size field of a Unicode file as 8 bytes, which has room for far more than 50 GB. The same Microsoft page gives different defaults for some versions in two of its tables, so check it for your version before you plan a split.

For the file itself, Microsoft's PST specification is the primary source, and Wikipedia gives a short summary.

Split a big EDB to PST export into several files

The export cmdlet gives you four levers for EDB to PST work. Every one comes from Microsoft's page for New-MailboxExportRequest.

Ways to keep a PST file small
Way How it works
By date The -ContentFilter option takes dates, but only from one date or to one date, and not between two. Two exports, one to a date and one from it, split the mailbox in two. The split is our idea, and we did not test it.
By folder The -IncludeFolders option exports the folders you list. Export big folders in their own files.
By archive The -IsArchive option exports the archive mailbox to its own file.
Without the dumpster The -ExcludeDumpster option leaves out the Recoverable Items folder, which is exported by default.

Plan the share first. Count the mailboxes and add their sizes before you convert EDB to PST. Leave room for every file, because a 200 mailbox store makes 200 PST files.

Why Does Converting EDB to PST Fail? Eight causes of failed EDB to PST exports, and the fix for every one

Eight causes stop EDB to PST conversion. Four are setup problems, namely a missing role, a share Exchange cannot reach, a bad item limit of 0 and an unmounted database. The fixes come from Microsoft's pages.

The Mailbox Import Export role is missing Microsoft says no role group has this role by default, and the cmdlet is not available without it. Fix: add the role to a role group that includes your account.
Exchange cannot write to the share Microsoft names the error. Exchange is unable to establish a connection to the PST file on the network share. Fix: give the Exchange Trusted Subsystem group read and write permission on the share, and use a path that starts with two backslashes.
A bad item stops the request The default -BadItemLimit is 0, so one corrupt item fails the request. Fix: set a value of 10 or lower when you accept losing a few items, then count the items afterward.
The database is not mounted or is damaged The cmdlet exports mailboxes, and mailboxes in dismounted databases are out of reach. Fix: read the state first with our EDB check, try the causes that stop a mount and use a recovery database. If the file is damaged, try an offline converter.
A mailbox has more than 10 requests Exchange makes up to 10 request names for a mailbox on its own. Fix: add -Name with a new name for the next export, and remove finished requests.
The Exchange 2007 computer is not set up Export-Mailbox needs a 32 bit computer with the 32 bit management tools and Outlook 2003 SP2 or later. Fix: set up that computer, and give your account full access to the source mailbox.
The PST file grew too big Outlook stops at the limits in the size section. Fix: split the export by date, folder or archive.
A free converter stops at 25 items Both vendor pages say the free version saves 25 items per folder. Fix: read the limit before you start, and test on one small mailbox.

A failed EDB to PST export can also leave a request behind. Microsoft says to remove a failed request by hand with the matching Remove- cmdlet, unless you set an expiry for requests.

Still short of mail after a good export? Count the items, as the check section shows. An EDB to PST request can finish and still leave items behind when the bad item limit is above 0.

What Did We Check, and What Did We Skip? The facts, their sources and the gaps

The cmdlet facts come from Microsoft's pages. The converter facts come from two vendor pages. The PST results come from our own tests. We used no Exchange server and no converter, so no EDB to PST conversion was tested.

What every part of this page rests on
Part Source
EDB to PST cmdlet options and errors Microsoft, New-MailboxExportRequest page. We read it, and we did not use the commands.
EDB to PST on Exchange 2007 Three archived Microsoft pages on Export-Mailbox, the export steps and the changed features. The export steps apply to Exchange 2007 SP1 to SP3.
Recovery database Microsoft recovery database guide. Our link between the restore and the export is our own reading.
PST size limits Microsoft page on Outlook data file limits. It disagrees with itself on some versions.
PST file structure The Microsoft PST specification, checked against our own test file.
Reader behavior Our tests. One PST file, 17 damaged copies, two readers and one script.
EDB to PST converters The SysTools and Freeviewer product pages. We read them and did not use the tools.

What we left out

We did not start Exchange, so we used none of the commands on this page. We did not use any converter, and we name no prices. We tested one Unicode PST file of 57 MiB, and we tested no ANSI file, no 4096 byte file and no file near the size limits.

Our 17 damaged copies come from one file. They show what can happen and not how common it is. Our results show what free readers and our script do with a PST file, and not what a conversion tool writes.

Sources checked

For EDB to PST export, see Microsoft on New-MailboxExportRequest and the export guide for Exchange 2016 and 2019. For Exchange 2007, see the archived Export-Mailbox page, the Exchange 2007 steps page and the changed features list.

For recovery and for EDB to PST files, see the guide to restoring with recovery databases, the Outlook data file limits and the PST specification. For a short summary of the format, see Wikipedia on the Personal Storage Table.

For converters, see the SysTools EDB to PST page and the Freeviewer EDB to PST page. Every count and label from our tests came from the files and scripts in our research folder.

Frequently Asked Questions About Converting EDB to PST

How do I convert EDB to PST?

Convert EDB to PST by exporting every mailbox to its own PST file. Exchange 2010 and later use New-MailboxExportRequest, and Exchange 2007 SP1 and later use Export-Mailbox. A dismounted file goes through a recovery database first. An offline converter works when only the EDB file is left.

What is the PowerShell command to convert EDB to PST?

For EDB to PST on Exchange 2010 and later the command is New-MailboxExportRequest with the mailbox name and the file path. Microsoft's example writes the mailbox AylaKol to PST on the network share. Your account needs the Mailbox Import Export role first.

Can I convert EDB to PST without Exchange Server?

Yes, with an offline EDB to PST converter. SysTools and Freeviewer both say their converters read the EDB file and save PST files with no live server. We read those pages and did not test the tools, so try the free version on one small mailbox first.

Is there a free way to convert EDB to PST?

The Exchange cmdlets for EDB to PST are part of Exchange, and they need a server you already have. Both vendor converters have free versions that save only 25 items per folder. Test with them and read the limit before you decide.

How do I convert a dismounted EDB file to PST?

To convert a dismounted EDB file to PST, copy the file and its logs, make the recovery database that points at the copy and mount it. Restore the mailbox you need into the spare mailbox and export that mailbox to PST. Dirty files need their logs replayed first.

Does ExMerge still convert EDB to PST?

ExMerge belongs to Exchange 2003 and 2000. Microsoft's Exchange 2007 pages list the Mailbox Merge Wizard among the replaced or removed features and point to the export cmdlet instead. Check which version a guide to EDB to PST was written for before you follow it.

Can I convert many EDB mailboxes to PST at once?

One EDB to PST export request makes one PST file, so a store with 200 mailboxes makes 200 files. A loop over the mailboxes starts the requests in one go. Our loop is built from the documented options and was not tested, so try it on two mailboxes first.

How do I check that the PST file is complete?

After EDB to PST conversion, compare the item count of the source mailbox with the items the request moved and with the folders in Outlook. Then use a script that checks the header and every data block. Our script flagged 15 of 17 damaged copies, while both free readers opened 8 of them with no error.

Why does my PST file open but look short?

Exchange skips bad items when the limit allows it, and the EDB to PST request still ends well. The default limit is 0, so a request that skipped items had its limit raised. Count the items against the source to find the gap.

How big can a PST file be?

A Unicode file stops at 50 GB by default in Outlook 2010 and later and at 20 GB in Outlook 2003 and 2007. An old ANSI file stops near 2 GB. Split a big EDB to PST export by date, folder or archive.

Can I convert a damaged EDB file to PST?

Servers will not mount damaged files, so the native EDB to PST cmdlets cannot start. Both vendors say their converters read damaged files with Quick and Advanced scans. We did not test them, so work on copies and count the items afterward.

Do I need Outlook to convert EDB to PST?

Not to convert EDB to PST on Exchange 2010 and later, because Exchange writes the file itself. Exchange 2007 needs a 32 bit computer with Outlook 2003 SP2 or later. SysTools says Outlook is optional for its converter, though its Use Outlook option wants a configured profile.

Still Stuck Converting EDB to PST? Seven routes out, depending on what went wrong

Your database will not mount

Read the state in the header and find the logs. The ten causes on the EDB page list what to try first.

The PST file opens but looks short

Count the items against the source, then use the PST script on the file.

Do you want the file explained first? The guide to EDB files covers the format, the state check and our tests of 18 ESE files, before you convert EDB to PST.

Is it an Outlook file? The page on PST files and the page on OST files cover Outlook data files.

Is your mail in another format? The page on MBOX files and the page on OLM files cover mail from other programs.

Is it the engine name? The page on ESEDB files covers the ending that the engine gives its files.

Is it a file type you do not know? Browse the file extension resource library, or send it to us on the submit a file type page.