Many teams want invoices, contracts and receipts from email in SharePoint, OneDrive or a cloud bucket, not in a mailbox. Mail Attachment Downloader puts them there. A rule picks the emails, saves the attachments, and its Upload to cloud step sends each saved file to a folder in your cloud storage, in subfolders and with names built from the email.
New in version 4.0. The examples use Contoso’s mailbox finance@contoso.com and invoices from Acme.
Which cloud storage can you save email attachments to?
One step works with all of these:
- Microsoft: OneDrive (personal, work or school) and SharePoint document libraries, Online and on-premises.
- Amazon S3 and S3-compatible storage: Wasabi, Backblaze B2, Cloudflare R2, DigitalOcean Spaces, Google Cloud Storage (with an HMAC key), MinIO and others.
- Azure Blob Storage.
- WebDAV: Nextcloud and ownCloud, pCloud, Koofr, Yandex Disk, a Hetzner Storage Box, a Synology or QNAP NAS, or any WebDAV server.
- File servers: SFTP, FTPS (FTP over TLS), and a network share (SMB) with its own sign-in.
- Google Drive and Dropbox: through your own Google Cloud or Dropbox app (more on that below).
What you need
- The edition: PRO Rules Client or PRO Rules Server. Upload to cloud is a step in a PRO rule, so Free, PRO Backup and PRO Parser don’t have it.
- Windows: Windows 10 or later, 64-bit, on a PC, a server or a cloud VM. No Outlook needed.
- The mailbox: Gmail, Google Workspace, Microsoft 365, Outlook.com, Exchange, or any IMAP or POP3 mailbox, added with Add account.
- The storage: an account at the service that may write to the folder or bucket.
Step 1: Connect your cloud storage once
Open Settings › Sources › Cloud Connections. Add each service or server once, with a name; rules then pick the connection by name, so many rules share one sign-in.
- Click Add… and choose the service.
- Fill in what it asks for (see the list below) and give it a Connection name, such as “Finance SharePoint”.
- Click Test, then OK.

What each service asks for:
- SharePoint and OneDrive: your Microsoft account. Sign in… opens Microsoft’s sign-in in the browser; sign in and accept. No password is kept.
- S3 and S3-compatible: pick the Provider (Amazon S3, Wasabi, Backblaze B2, Cloudflare R2…), then the Endpoint, Region, Access key ID and Secret access key of a user that may list, read and write the bucket.
- Azure Blob Storage: the Storage account and its Account key, or a SAS token for one container.
- WebDAV: pick the Provider, such as “Nextcloud or ownCloud”, and enter the Server URL, User name and an app password where the service has them.
- SFTP and FTPS: the Server, Port, User name and a password (SFTP can use a private key). The first Test shows the server’s host key or certificate to check and accept. Plain FTP isn’t offered: it sends the password unencrypted.
- Network share: the Share, such as
\\fileserver\Finance, with its own user name and password. Nothing is mapped to a drive letter.
Google Drive and Dropbox: with your own app
Google Drive and Dropbox connect through an app you make in your own Google Cloud or Dropbox account. It takes a few minutes. The window says what to do, and How to create one opens a guide.
- Google Drive: in the Google Cloud console, enable the Google Drive API, publish the OAuth consent screen (or the sign-in stops working after 7 days) and create an OAuth client ID of type “Desktop app”. Paste its Client ID and Client secret, or use Load both from the downloaded JSON file…, then click Sign in….
- Dropbox: in the Dropbox App Console, create a Scoped access app with Full Dropbox, tick files.content.write and files.metadata.read, and copy the App key. Click Sign in…, allow access, paste the code Dropbox shows into Code and click Continue.

Later, Sign in again renews a sign-in that stopped working, and Show rules lists the rules that use a connection.
Step 2: Add the Upload to cloud step to a rule
New to PRO Rules? Save emails and attachments to folders walks through a first rule.
- On the PRO Rules tab, click New rule….
- Under Which emails, click Add a condition, for example the sender’s domain acme.example, or “invoice” in the subject.
- Under Save, choose what to save and where, such as the attachments to
D:\Finance\Invoices. The upload sends these saved files. - Under Then, click Add a step…, open Other systems and double-click Upload to cloud.

Now set up the step:
- In Cloud connection, pick the connection. Manage… opens Cloud connections if it isn’t there yet.
- Next to Destination, click Browse… and choose the folder: the site, library and folder in SharePoint, the bucket and folder in S3, the container in Azure Blob, a folder on the server or share. New folder makes one.
- Run is For each saved file: each attachment the rule saves is uploaded.
- Click Test upload. It uploads a small test file to the destination and deletes it again, so you know the connection and the folder work.
- Click Save.

Subfolders and file names from the email
Open More options on the step to build the path in the cloud from fields, such as the date, the sender or the subject. Click Fields… next to a box to pick one.
- Subfolders: folders inside the destination.
{DATE[yyyy]}/{DATE[MM]}files each invoice under its year and month, such as Suppliers/2026/04. Folders that aren’t there yet are made. Left empty, files go straight into the destination. - File name: left empty, the file keeps the name it was saved with.
{FROM}_{FILENAME}{EXT}puts the sender in front of the attachment’s name.
Characters a service doesn’t accept are replaced, and a name that is too long is shortened.
![The Upload to cloud step in the Rule Editor of a rule named Supplier invoices: Cloud connection Invoices archive, Destination acme-invoices › Suppliers, Run For each saved file, Subfolders {DATE[yyyy]}/{DATE[MM]}, File name {FROM}_{FILENAME}{EXT}, If the name is taken Keep both (add a number), and the Test upload and Diagnostics buttons](https://i0.wp.com/gearmage.com/assets/images/4.0-cloud-upload.jpg?w=840&ssl=1)
When a file with the same name is already there
If the name is taken decides what happens:
- Keep both (add a number), the default: the new file gets a number added to its name. Nothing is overwritten.
- Replace it (new version): the new file takes the place of the old one.
- Skip the upload: the file already there stays, and the step counts as done.
- Fail the step: the step fails, and the Downloads tab shows it.
More options worth knowing
- Keep no local copy: tick Delete the saved file after the upload.
- Email details as SharePoint columns: for SharePoint and OneDrive, tick Add the email’s details as columns and choose them with Details…, such as the sender and the subject. They show in the library’s views and search.
- Steps after the upload: steps inside Upload to cloud can use
{CLOUD_URL},{CLOUD_PATH}and{CLOUD_FILENAME}, such as a link to the file. - When an upload fails: a busy or offline service is tried again a few times. Diagnostics… shows what went wrong.
- Nothing uploaded twice: each account’s History remembers the emails it has handled, so the next run doesn’t upload the same email again.
Before you turn the rule on, click Test this rule… to see which emails it picks.
What leaves your computer
- Only what the step uploads: the files the rule saved (and, for SharePoint and OneDrive, the email details you chose as columns) go straight from your own system to the service you picked. There is no Gearmage cloud in between.
- Secrets stay encrypted: access keys, passwords, private keys and sign-in tokens are kept encrypted on this computer, never in the settings or the logs. Diagnostics keep times, results and errors, never passwords or tokens.
Upload around the clock as a Windows service
Uploads run whenever the rule runs: on the program’s schedule, or as soon as new email arrives. To run 24×7, even when nobody is signed in, install the Windows service with PRO Rules Server: Schedule › Service schedule › Install service. Two things to know:
- Reinstall after a change: the service uses the connections it copied when it was installed. After adding or changing a connection, or signing in again, click Reinstall… so the service gets the change.
- Network shares: the service runs as Local System, which can’t open most shares. Add the share as a Network share (with its own sign-in) connection with a user that may write to it.

More on the service: save Outlook attachments to a network folder automatically.
The other way round: watch a cloud folder
PRO Rules Client can also watch a SharePoint library, OneDrive, an S3 or S3-compatible bucket, or a network share, and send each new file through your rules. The other services can be uploaded to, but not watched yet. See watch SharePoint, OneDrive and S3.
Try it: download Mail Attachment Downloader and start with the free edition, or compare the PRO editions, each with a 30-day money-back guarantee.
Related
- Upload to cloud storage: features
- What’s new in Mail Attachment Downloader 4.0
- Save emails and attachments to folders with PRO Rules
- Customizing file names or email data using fields
- Save Outlook attachments to a network folder automatically
Questions about this post? Contact us.