Extract, save attachments from multiple Outlook emails

When you use Outlook on a daily basis, you are faced with a large number of emails with attachments. The tedious task of manually extracting these attachments can be time-consuming and inefficient. However, through the use of an Excel macro, you can automate the process of mass extracting attachments from all emails in a folder and its subfolders.
In this article, we will show you how you can easily recover all images from an Outlook folder or all PDF files for example.

User guide for retrieving attachments from multiple emails

Follow the steps below to extract attachments in bulk.

Download Excel Macro VBA file

Download the Excel file with VBA macro to your computer via the button below. Save it to an easily accessible location that allows macros to run (outside of OneDrive or SharePoint…)
If you are using Windows 10 or 11: right click on the file, Properties, check Unblock to be able to use macros.

Validating Excel macros

Open the downloaded Excel file.
If security warnings appear, click “Enable Macros” or “Allow Content” to allow macros to run.

Selecting the destination folder for attachments

In the Excel file, find the “Select folder where attachments will be downloaded” section.
Click the button associated with the folder selection.

Sélection du dossier pour télécharger les pièces jointes de plusieurs mails en masse

Browse your folders and choose where you want to store the extracted attachments.
Confirm your selection and close the dialog box.

Selecting the Outlook folder to process for saving files

In Outlook, select the folder you want to process.
Be careful in your selection because attachments from all subfolders in your selection will also be downloaded.

All emails in the selected folder (and all its subfolders) will be searched and all attachments will be retrieved.

If you select « Inbox », you will go through all your emails. The processing time will be extremely long if you have many emails.

We advise you to select a particular file to process.

Launching the program to extract attachments from emails

In the Excel file, find the “Start import” button.

Click this button to retrieve attachments.

Let the process run until all attachments are downloaded.

Follow the on-screen prompts to monitor progress. If your file contains many emails with many attachments, processing may take a long time.

To exit a process that seems too long, click Esc.

To test how the mass processing file for email attachments works, start by testing a few emails and a few attachments.

Logiciel pour sauvegarder les documents attachés à plusieurs e-mail Outlook

Additional settings to download Outlook email attachments in bulk

Settings can be made to define which files should be extracted and which should not.

By default, if these settings are not implemented, all attached files will be extracted.

Selecting file extensions

List of extensions to exclude from processing:

By filling in this column, for example: png.
Any files with .png extension will not be downloaded.

List of extensions to recover:

By specifying elements in this list, only files with this extension will be extracted.
For example, to obtain all PDF files, you must enter PDF in this column.

Selecting the names of attached documents

Exclusion of words:

So that files that contain a specific word or group of words are not downloaded by the mechanism, these words must be specified in this section.
For example, to exclude all files that contain the word image: enter the word image.

Word contained in file name:

If you only want to download files that have certain words in the file name, they must be completed there.

Examples of group processing of Outlook email attachments

We present 3 possible uses of this software but from these examples you can adapt it to your needs.

Extracting all images from a folder and its subfolders

To extract all the attached images contained in your emails, you must enter the different extensions that the images may have.

Indicate these extensions in the column: Only the following extensions will be imported.

  • JPEG
  • JPG
  • PNG
  • GIF
  • BMP
  • TIFF
  • SVG
  • RAW
  • PSD
  • EPS
  • AI

Recovering all PDF files from a folder and its subfolders

To retrieve only PDFs from your emails, you can enter PDF in the column: Only the following extensions will be imported.

Save all attached emails

If you want to save the attached emails contained in your emails, enter MSG in the appropriate column.

Exclude files that contain the word image in the file name

When downloading attachments, you will also download images that are contained in email signatures. A solution to not recover all these files is to exclude file names that contain the word Image.

List of saved attachments from the export

Attachments are saved in the folder that was defined.

In addition, a list of all attached documents is available on the second tab of the Excel file. For each file, a hyperlink allows you to open the document by simply clicking on the file name.

Liste des pièces jointes récupérées

The benefit of mass extraction of attachments from Outlook emails

The advantages of mass mining PCs over manual mining:

  • Save time and effort through automation
  • Simplifying file management and organization

With the power of this Excel tool, automatically extracting attachments from multiple Outlook emails becomes a simple and efficient process. By following the steps given in this article, you can save valuable time and recover important files easily. Remember to adapt the search parameters according to your specific needs.

Customization of the file for serial extraction of email attachments

If you wish to personalize by adding options to the file available for download, we can agree on an exchange to clarify your request and consider its realization, please contact us.