Apple has included the Mail app in all of its Macs so you can get started with your emailing tasks as soon as you get a new Mac. Over the time as you use the app, you will notice that the app slows down and leaves you thinking what you did wrong that has slowed it down. Well, the reason is that the database of the emails grows larger as you send and get new emails and that’s the main reason the app is not performing as fast as it first did.
There are also fragmentation issues that slow down the app, and at the end, you are left with an app that takes ages to let you send an email. That’s utterly frustrating, and if you’re in such a situation, you’d probably be thinking to switch to another email app for your emailing tasks.
However, if you have been a long time Mail user, you might not want to leave the app. If that’s you, there are some things that you can do to speed up the Mail app on your Mac. As I said above, since the primary cause of the slowdown is the database, you need to clean it up to speed up the app, and that’s exactly what you’re going to do in the following guide.
To clean up the database, you don’t need to manually do anything as you can just create a workflow in the Automator app on your Mac and it will run whenever you want. That way it will automatically clean up the database without requiring you to perform any manual tasks.
So first we’ll learn how to create the workflow which you will then run to clean up the Mail app’s database. Here you go folks:
Speeding Up the Mail App on a Mac
Make sure the Mail app is not open on your Mac. If it is, close it by clicking on the Mail menu on the top and selecting Quit Mail and the app will be closed. The script below will close the app, though, but we’ll close it just in case.
Here are the steps to create a workflow for cleaning up the Mail database:
1. Launch the Automator app on your Mac by clicking on Launchpad in the Dock and searching for and clicking on Automator. The app should launch.
2. When Automator launches, click on the File menu at the top and select the option that says New to create a new workflow. You can also press Command + N to create a new workflow in the app.
3. On the following screen, you will be asked what kind of document you would like to create. You need to choose the type that says Workflow which should be the first one in the list and then click on Choose to begin creating a new workflow in Automator.
4. In the left-hand side panel, you will see the actions list. From that list, find the action named Quit Application and drag and drop it onto the workflow on the right.
5. Get your focus in the workflow panel and click on the drop-down menu for the action you just dragged over and select Mail. What you’re doing here is telling it to quit the Mail app if it’s open.
6. Drag the action named Run Shell Script from the actions list over to the workflow on the right.
7. Remove everything from the shell script box. Then, copy and paste the following command into that box depending on the version of the OS of your Mac.
sqlite3 ~/Library/Mail/V4/MailData/Envelope\ Index vacuum;
sqlite3 ~/Library/Mail/V3/MailData/Envelope\ Index vacuum;
8. Drag the action named Launch Application from the actions list over to the workflow.
9. Click on the drop-down menu for the Launch Application action and select Mail as the app to be launched.
10. Your workflow is ready to be executed. What you need to do now is save it, and you can do that by clicking on the File menu at the top and selecting Save.
11. Enter a name for the workflow and click on Save to save it. You can then click on the Run button in Automator to run the workflow, and it will clean up the Mail database for you.
So, that was how you could speed up the Mail app if it’s slowed down on your Mac by cleaning up the database.