Skip to content

Messages keeps every attachment ever sent to you, forever

The Messages attachments folder is one of the largest hidden folders on a long lived Mac. How to find the big ones and delete them safely.

5 min read

Messages has been on the Mac for over a decade, it keeps every attachment anyone has sent you, and it has no interface for finding the large ones. On a Mac that has been migrated from machine to machine since 2014, this is regularly one of the largest folders in the home directory.

Where it is

du -sh ~/Library/Messages/* 2>/dev/null | sort -h

Attachments is almost always the large one. chat.db is the message database itself and it is comparatively small, because text is small. What fills the folder is video, and after that images.

Finding the attachments worth removing

find ~/Library/Messages/Attachments -type f -size +20M \
  -exec ls -lh {} + 2>/dev/null | sort -k5 -h | tail -20

That is every attachment over 20 MB, largest last. In practice this is a short list of videos, and removing ten of them is worth more than removing ten thousand images.

The safe way to remove them

Deleting attachment files by hand leaves the message referring to a file that no longer exists, which shows as a broken attachment in the conversation. That is cosmetic rather than damaging, but there is a cleaner route inside the app: open a conversation, click the details button, and remove items from the shared photos and files list there.

For bulk removal by date, Messages can do it for you. In Settings, General, there is a Keep messages setting with options for 30 days, one year or forever. Changing it from forever to one year removes old messages and their attachments together, consistently, which is the version that leaves nothing broken.

If Messages in iCloud is turned on

With Messages in iCloud enabled, deleting on the Mac deletes everywhere, including on your phone. That is the intended behaviour of a synced service and it surprises people every time. If you want the space back on the Mac only, the option is to turn the sync off first, which is a different decision worth thinking about separately.

The same logic applies across everything Apple syncs, and what the storage recommendations actually do covers the ones that move data rather than delete it. Mail attachments behave differently again and are worth checking at the same time.

Common questions

Where are iMessage attachments stored on a Mac?

In ~/Library/Messages/Attachments, alongside the chat.db message database. The database itself is usually small because text takes little space, and the attachments folder holds the videos and images that make up the bulk.

Is it safe to delete iMessage attachments?

Deleting the files directly leaves broken attachment placeholders in conversations, which is cosmetic. The cleaner options are removing items from a conversation's details panel, or setting Messages to keep messages for one year rather than forever.

Will deleting messages on my Mac delete them on my iPhone?

If Messages in iCloud is turned on, yes. The service syncs deletions to every device. If it is off, the Mac's copy is separate and removing it affects only the Mac.

How do I find the largest iMessage attachments?

Use find against ~/Library/Messages/Attachments with a size filter, for example files over 20 MB, and sort the results. It is almost always a short list of videos, which makes the cleanup quick.

Read next