PST.Kit for Delphi – read Outlook PST and OST files without Outlook

PST.Kit iconOutlook data files, read directly from the file

PST.Kit is a Delphi library that reads Outlook data files – personal folders (.pst) and offline folders (.ost), ANSI and Unicode, with 512-byte and 4 KB pages – directly from the file, by Microsoft’s open specification [MS-PST]. It needs no Outlook, no MAPI and no COM, and it never writes to the file.

PST.Kit is the engine of our free PST Inspector. Files of any size are read through a memory-mapped file (Win64) or plain file reads (Win32).

Delphi 13 Florence · Win32 and Win64 · no Outlook, no MAPI, no COM · VCL-free (console, service, GUI) · read-only

What PST.Kit is for

  • The folder hierarchy with item counts, contents tables, search folders and receive folders.
  • Messages with their recipients, attachments and embedded messages at any depth.
  • Every property, including the named properties, by tag or by canonical name (PidTagInternetMessageId, PidLidTaskStatus).
  • The best body: HTML, RTF (compressed RTF decoded) or plain text, as Outlook would choose it.
  • Signed and encrypted messages (S/MIME and OpenPGP) together with Crypto.Kit and MIME.Kit.
  • Every message is also a message source for the other kits: save it as .msg (Msg.Kit), .eml, iCalendar or vCard (MIME.Kit), or compare it with a JSON property dump.
  • Rendering helpers: a message as HTML for a viewer, sticky-note colours.

How it is organised

  • One uses PSTReader.PSTFile; gives TPSTFile, TPSTFolder, TPSTMessage, TPSTAttachment, TPSTRecipient and TPSTTable; PSTReader.PSTElementProperties adds the enumerations, Shared.PropTags the property ids.
  • Under the object model lie the layers of [MS-PST]: the on-disk structures, the node and block database (NDB), the lists, tables and property contexts (LTP) and the B-trees.
  • File sources: memory-mapped or buffered file reads; PSTReader.Render.Html and .Vcl for viewers.
  • Clear rules: objects reached through a property belong to their parent, objects returned by a function belong to the caller; a damaged file raises EPSTException, a damaged folder keeps what it could read and reports the rest; every date is local time, every string a plain Delphi string.

Getting started

The folder tree of a .pst file with the subject of every message. The messages of each folder are read through an own folder instance, so that a large file does not stay in memory:

uses System.SysUtils, PSTReader.PSTFile;

procedure Walk(AFile: TPSTFile; AFolder: TPSTFolder; const AIndent: string);
var
  Sub, Own: TPSTFolder;
  M: TPSTMessage;
begin
  Writeln(AIndent, AFolder.DisplayName, ' (', AFolder.ContentCount, ')');
  if AFolder.ContentCount > 0 then
  begin
    Own := AFile.GetFolder(AFolder.NID);     // owned by us: its messages are freed with it
    try
      for M in Own.Messages do
        Writeln(AIndent, '  ', DateTimeToStr(M.Date), '  ', M.From, ': ', M.Subject);
    finally
      Own.Free;
    end;
  end;
  for Sub in AFolder.Folders do
    Walk(AFile, Sub, AIndent + '  ');
end;

var
  Pst: TPSTFile;
begin
  Pst := TPSTFile.Create('C:\Mail\archive.pst');
  try
    Walk(Pst, Pst.IpmSubTree, '');
  finally
    Pst.Free;
  end;
end.

The best body, the recipients and the attachments of a message; a property by its canonical name and the property dump:

procedure ShowMessage(M: TPSTMessage);
var
  R: TPSTRecipient;
  A: TPSTAttachment;
begin
  Writeln(M.Subject);
  for R in M.Recipients.ToRecipients do
    Writeln('  To: ', R.DisplayName, ' <', R.EMailAddress, '>');
  Writeln(M.BestBodyAsText);                 // HTML, RTF or text -- whichever is best
  for A in M.Attachments do
    if A.IsFile then
      A.SaveToFolder('C:\Temp\Attachments');
  Writeln(M.PropertyValue('PidTagInternetMessageId').ToString);
  M.SavePropertyDump('C:\Temp\message.json');    // the same format in every kit
end;

More examples, the rules of ownership, errors and time zones, and every class, property, method and routine are in the Class Reference and Developer Guide.

Part of the IMIBO mail toolkit

Every kit gives the same answer for the same message: the kits share one property catalogue, one message contract and one JSON property dump, so a message read by one kit can be written, converted or compared by any other.

MAPI.Kit · PST.Kit · Msg.Kit · MIME.Kit · Crypto.Kit · Autodiscover.Kit · Graph.Kit · EWS.Kit

PST.Kit is developed by IMIBO; the source code is not public. For licensing, custom development or questions write to info@imibo.com.

PST.Kit Class Reference and Developer Guide (PDF)

Pages of the PST.Kit Class Reference and Developer Guide

PST.Kit 1.00 – Class Reference and Developer Guide · PDF, 52 pages, English, October 2026. Introduction, requirements and rules, the units at a glance, getting started, dates and strings, and the class reference – the PST file, folders, messages, properties, tables and folder views, rendering, file sources, helpers – with signed and encrypted mail, examples and the road map.

The document is free. Enter your email address and you will receive a personal download link.

PST.Kit Class Reference and Developer Guide – PDF, 52 pages, English, free.

Enter your email address and we will send you a personal download link (valid 72 hours).


Questions about PST.Kit: info@imibo.com.

Example application: PSTInspectorLite (free download)

PSTInspectorLite iconPSTInspectorLite is a free, read-only viewer of Outlook data files written with PST.Kit – the same program as GraphInspectorLite and EWSInspectorLite with another data source: .pst files (ANSI and Unicode) and .ost files (Exchange, Microsoft 365, IMAP and Outlook.com accounts) with their folder trees, the items of a folder page by page with sorting and a local search (subject, sender, recipients, categories and body), the MAPI properties with their descriptions, recipients and attachments of every item, messages with a safe HTML view (no scripts, external pictures blocked until you allow them), Save as .msg / .eml, calendars, contacts and tasks, light and dark themes. It needs no Outlook, opens a file from the menu, the command line or by drag and drop, and never changes it.

Screenshots

User guide

The guide of PSTInspectorLite, as it comes with the program (UserGuide.md in the ZIP). Open a section to read it.

PSTInspectorLite is a read-only viewer of Outlook data files — .pst (Personal Folders, ANSI and Unicode) and .ost (Outlook’s offline data file: the local copy of an Exchange / Microsoft 365 mailbox, and since Outlook 2013 also of IMAP and Outlook.com accounts): the mail folders, the messages with their MAPI properties, recipients and attachments, the calendars, contacts and tasks. It is built on the IMIBO kits (PST.Kit, Msg.Kit, MIME.Kit, Crypto.Kit, Shared), needs no Outlook and has no third-party code. It never changes a file.

It is the same program as GraphInspectorLite (Microsoft 365 / Outlook.com through Microsoft Graph) and EWSInspectorLite (on-premises Exchange through EWS) with another data source: the windows, lists, panels and item windows are the shared viewer of Shared\Vcl\Inspector. It is a separate program from PSTInspector, the full PST analysis tool (its settings and files are kept apart).

  • Windows 10 or 11 (64-bit or 32-bit build; a data file of many gigabytes is best opened with the 64-bit build).
  • For HTML message bodies: the Microsoft Edge WebView2 runtime (part of Windows 11, installed with Edge on Windows 10) and WebView2Loader.dll next to PSTInspectorLite.exe (the build copies it there, see “Files”). Without them the bodies are shown as plain text.
  • Read access to the data file. A file Outlook has open can be read as well (it is opened for reading, shared); what you see is what was in the file when it was read — View > Refresh reads the folder again.
  • File > Open data file (.pst, .ost)… and pick the file, or
  • drop a .pst / .ost on the window, or
  • start the program with the file (Open with…, or the file dropped on PSTInspectorLite.exe).

The file is opened at once; a file that is no PST / OST (or a damaged one) is refused with the reason. It appears in the tree as “store name <full path>” (an .ost without a store name shows its file name) and is opened again at the next start. File > Close the selected data file… takes it off the list — the file itself is not touched.

PSTInspectorLite does not ask for a PST password: that password is only a check Outlook makes, it does not encrypt the data.

  • The tree (left): one root per data file; under it the mail folders of the mailbox part (“Top of Personal Folders” / “Top of Information Store”: Inbox, Sent Items, … with the unread count), then Calendars, Contacts and Tasks with every folder of that kind in the file. Hidden system folders (search roots, views, conversation settings, …) are not shown, as in Outlook. Folders are read when they are expanded.
  • The list (right): the items of the selected folder, with columns of its kind:
    • mail: From, Subject, Received, Size, Attachment, Flag, Importance — unread messages in bold, newest first;
    • calendar: Subject, Start, End, Location, Organizer, Recurring, All day (a recurring series is one row), newest first;
    • contacts: Name, Company, E-mail, Phone, by name;
    • tasks: Title, Due, Completed, Status, Importance, by due date.

The list is read 50 items at a time in the background; the next 50 come when the last row scrolls into view. A click on a column header sorts the rows read so far (again: the other direction); Ctrl+C copies the selected rows.

  • Search (above the list): type words and press Enter — every word must occur (case-insensitive) in the subject, the sender, To / Cc, the categories or the body (plain text, HTML or rich text; a signed / encrypted body is not searched); Esc clears it. The search runs on this computer through the selected folder, a few hundred items per step: the hits appear while it goes on, and another folder stops it.
  • View > Refresh (F5) reads the folder again.
  • The details panel (below the list, View > Details panel) shows the selected item — or, with no item selected, the folder itself:
    • Properties: the stored MAPI properties — tag, canonical name, type, value, description (named properties by their name from the file’s name-to-id map); a tooltip on a property tells what the property catalog knows of it (description, tag / ID / type, area, property set and LID / name of a named property, other names); a double click, Enter or Property details… in the context menu opens the property window — that information, the whole value and its bytes as a hexadecimal or binary dump;
    • Recipients: kind (To, Cc, Bcc, …), name, address;
    • Attachments: name, size, type, kind; Save as… / Save all to a folder… from the context menu, a double click saves one. With a folder selected, the status bar gives its number of items and unread items and of its properties.

A double click (or Enter) on a row opens it in its own window; several windows can be open at once.

  • A message: From, To, Cc, Date, Subject; the attachments (inline pictures are shown in the body, not listed); Save as .msg (an Outlook message file) and Save as .eml (an Internet message). The body is the HTML body, else the rich-text (RTF) body as HTML, else the plain text. It is shown safely:
    • no scripts run, and nothing is loaded from the network — pictures that are part of the message are shown;
    • when the message refers to pictures or styles on the internet (newsletters, tracking pixels), a bar says “External pictures and styles are blocked to protect your privacy”; Show external content loads them for this message (still without scripts);
    • a link opens in your default browser, never inside PSTInspectorLite.
  • An event, a contact or a task: the fields that are set (times, time zone, recurrence in words, attendees, reminder, addresses, phones, status, …) and the description / notes below them.

View > Theme: System (the default — follows Windows’ light / dark app mode, also while the program runs), Light or Dark. The icons follow the theme.

What Where
The opened data files (path, store name, kind) %LOCALAPPDATA%\IMIBO\PSTInspectorLite\accounts.json
The theme setting %LOCALAPPDATA%\IMIBO\PSTInspectorLite\settings.json
The WebView2 profile (cache of the body view) %LOCALAPPDATA%\IMIBO\PSTInspectorLite\WebView2
A shown HTML body (while its window is open) %TEMP%\PSTInspectorLite-<guid>.html (deleted on close)
WebView2Loader.dll next to PSTInspectorLite.exe (from Shared\Vcl\Inspector\redist\WebView2.<platform>)

Nothing is written into a data file, and no credential is kept.

  • PSTInspectorLite\PSTInspectorLite.dproj (Win64 / Win32), search path ..\Shared;..\Shared\Vcl; ..\Shared\Vcl\Inspector;..\PST.Kit;..\Bridge;..\Msg.Kit;..\MIME.Kit;..\Crypto.Kit;..\MAPI.Kit;..\Autodiscover.Kit (include path ..\MAPI.Kit) — no third-party code. The program’s own units are PSTInspectorLite.dpr and PstInspectorLite.Backend (the data-file source of the viewer); the data source itself is PST.Kit’s PSTReader.MailboxSource, the viewer is Shared\Vcl\Inspector. The post-build event copies the platform’s WebView2Loader.dll (Microsoft’s NuGet package Microsoft.Web.WebView2, see Shared\Vcl\Inspector\redist\README.md) next to the exe.
  • Optional: the conditional define HTMLVIEWER (with $(HtmlViewer)\source on the search path) shows HTML bodies in THtmlViewer when WebView2 is not available — the one third-party component, opt-in.
  • Read-only: nothing is changed in the file (opening a message does not mark it as read).
  • The stored properties are shown as the file keeps them — no properties a store provider would calculate.
  • Hidden folders and the part of the file above the mailbox (search folders, views, …) are not in the Lite version; PSTInspector shows them.
  • A large folder is read once when it is selected (the 15,000-message Inbox of a 17 GB test file: about one second).

The download (ZIP, 7.1 MB) contains:

  • Win64\PSTInspectorLite.exe and Win32\PSTInspectorLite.exe – the program, no installation (with Microsoft’s WebView2Loader.dll next to it).
  • Source\ – the complete source code of PSTInspectorLite and of the viewer it shares with GraphInspectorLite and EWSInspectorLite (Delphi 13, VCL): the project, its units and forms, the icon.
  • UserGuide.md and README.txt.

Note: The ZIP holds the executable and the source code of the program, but not the libraries it is built on – PST.Kit, the shared units, Msg.Kit, MIME.Kit and Crypto.Kit; to compile the source you need those kits. For the full analysis of a data file (hidden folders, the raw B-trees and blocks, consistency checks, export of many messages) use PST Inspector.

Enter your email address and you will receive a personal download link.

PSTInspectorLite – ZIP, 7.1 MB: the program (64-bit and 32-bit) and its source code, without the kits it is built on, free.

Enter your email address and we will send you a personal download link (valid 72 hours).


Questions about PSTInspectorLite: info@imibo.com.

Intelligence Management Interface BackOffice - IMIBO - Logo

Copyright © 2026 IMIBO. Privacy Statement