DEV Community

chris
chris

Posted on

How I Fixed My Mac's Slow Spotlight and Recovered 30GB of Storage

Introduction

For a while, I noticed that my Mac's Spotlight search had become extremely slow and was unable to find certain folders. I also realized that my available storage was mysteriously shrinking, even though I hadn't installed large applications or downloaded massive files. After some troubleshooting, I managed to fix my Spotlight search issue and reclaim about 30GB of storage space. Here's a step-by-step guide on how I did it.


Identifying the Problem

  • Slow Spotlight Searches: Searching for files took much longer than usual, and some folders weren’t appearing in the search results.
  • Mysterious Storage Consumption: My available disk space had shrunk to 220GB, with a significant portion occupied by 'System Data' in macOS storage settings.
  • Large .Spotlight-V100 Index: After some investigation, I found that Spotlight's indexing folder was taking up a significant amount of space.

Step-by-Step Solution

1. Checking Disk Usage

Before making changes, I verified my disk usage:

  • Opened Finder > Applications > Utilities > Disk Utility
  • Selected my Macintosh HD and ran First Aid to check for any disk errors.
  • Used About This Mac > Storage to identify large storage consumers.

2. Rebuilding Spotlight’s Index

Since the .Spotlight-V100 folder can grow excessively large or become corrupted, I decided to rebuild the Spotlight index.

Using System Settings

  1. Went to System Settings (or Preferences in older macOS versions) > Spotlight > Privacy.
  2. Clicked the + button and added Macintosh HD to the privacy list.
  3. Removed Macintosh HD from the privacy list after a few seconds.
  4. This triggered macOS to reindex my entire drive automatically.

Using Terminal (Alternative Method)

If the above method didn’t work, I had planned to use the following command in Terminal:

sudo mdutil -a -i off   # Turns off Spotlight indexing
sudo rm -rf /.Spotlight-V100   # Deletes old Spotlight index
sudo mdutil -a -i on    # Re-enables Spotlight indexing
sudo mdutil -aE         # Forces a reindex
Enter fullscreen mode Exit fullscreen mode

Since the first method worked, I didn't need to run these commands, but they remain a solid alternative for advanced users.

3. Monitoring Storage Changes

After reindexing, I checked my storage usage again:

  • Opened Finder and pressed Command + Shift + G to go to /System/Volumes/Data/.Spotlight-V100.
  • The folder size had shrunk significantly, reclaiming around 30GB of storage space.
  • My available storage increased from 220GB to 190GB, showing the effectiveness of the fix.

Final Thoughts

Rebuilding Spotlight’s index not only fixed my slow search issue but also freed up a significant amount of space that had been occupied by a bloated indexing database. If you're experiencing sluggish Spotlight searches or unexplained storage loss, I highly recommend trying this method.

Have you faced similar issues with Spotlight? Let me know your experience in the comments!

AWS GenAI LIVE image

Real challenges. Real solutions. Real talk.

From technical discussions to philosophical debates, AWS and AWS Partners examine the impact and evolution of gen AI.

Learn more

Top comments (0)

Postmark Image

Speedy emails, satisfied customers

Are delayed transactional emails costing you user satisfaction? Postmark delivers your emails almost instantly, keeping your customers happy and connected.

Sign up

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay