iPhoto 5 or earlier: Rebuilding the iPhoto Library

iPhoto includes a feature that allows you to rebuild the currently selected iPhoto library. Sometimes rebuilding the library resolves issues such as the library appearing to be unreadable, missing photos, or other issues related to reading the iPhoto library structure.

Note: This article is for iPhoto versions 5 and earlier. For iPhoto 6 and later see this article instead.

This article has been archived and is no longer updated by Apple.

Important: You should back up your existing iPhoto Library folder before using the rebuild feature. A backup allows you to restore the iPhoto Library should anything unexpected happen during the rebuild (such as an unexpected shutdown) that prevents the library from rebuilding correctly.

Before performing a rebuild, you should install any iPhoto updates you find by using Software Update. If a software update resolves your issue, then you don't need to rebuild. It's also a good idea to search apple.com/support for your specific iPhoto symptom before performing a rebuild, just in case there is a more specific or relevant solution.

To rebuild iPhoto 5 and earlier you will need at least enough free disk space equal to your current iPhoto library.

Follow these steps to rebuild the iPhoto library:

  1. Quit iPhoto if it is open.
  2. For iPhoto 2, hold down the Shift and Option keys on the keyboard.
    For iPhoto 4 and iPhoto 5, hold down the Command and Option keys on the keyboard.
  3. Open iPhoto.
  4. Keep the keys held down until you are prompted to rebuild the library.
  5. Name and save the library.

iPhoto will begin to rebuild the iPhoto library. This can take several minutes, depending on its size.

Note: iPhoto 5.0.2 and later include an additional dialog that appears when you start to rebuild the library.

Use these guidelines for these dialog options:

  • Select the option(s) for thumbnails if only the thumbnails are appearing in unexpected ways (grey or blank).
  • Select the "Rebuild the iPhoto Library database" option if iPhoto unexpectedly quits when launched or does not get past loading photos.
  • Select the option to recover orphaned photos if photos appear to be missing from the iPhoto library.

If there was an issue with album data or with the iPhoto library file itself, then some of the albums may appear blank after rebuilding the library. Look in the main library in the source list of the iPhoto -- the photos are likely still there. If so, drag the photos to their corresponding albums to add them back to the library.

Performing a "Manual rebuild"

If the built-in iPhoto rebuild option does not appear to resolve the issue you are experiencing, you can manually reimport the photos into a new iPhoto library by using the steps below. You will need at least enough free disk space equal to your current iPhoto library to complete this procedure.

Manual rebuild for Mac OS 10.4 and later:

  1. While holding the Option key, open iPhoto.
  2. When prompted, select the option to create a new library.
  3. From the iPhoto menu, choose Hide iPhoto.
  4. Locate the iPhoto Library folder in the Finder (it should be in your Pictures folder), and open it.
  5. Choose Find from the File menu.
  6. Change the search scope to find files in "this folder" whos size is "greater than 30KB" and kind is "Images". Click the + or - buttons in the Find window to add or remove search parameters.
  7. Click the iPhoto icon in the Dock.
  8. Drag the search results into the blank iPhoto window to import these images.

Manual rebuild for Mac OS 10.3.9 and earlier:

  1. While holding the Option key, open iPhoto.
  2. When prompted, select the option to create a new library.
  3. From the iPhoto menu, choose Hide iPhoto.
  4. Locate the iPhoto Library folder in the Finder (it should be in your Pictures folder).
  5. Choose Find from the File menu.
  6. Change the search scope in the Find window to "Search in: Specific Places".
  7. Drag the iPhoto Library folder from the Finder window into the list of search locations to add it.
  8. Make sure only the iPhoto Library is selected in the search list.
  9. For "Search for items whose:" in the Find window, use the search attributes "Kind is Image" and "Size is greater than 30 KB". Click the + or - buttons in the Find window to add or remove search terms.
  10. Click Search.
  11. Click the iPhoto icon in the Dock.
  12. Drag the search results into the blank iPhoto window to import these images.

Tip: The iPhoto library is usually located in the Pictures folder of your home folder. If you are unable to locate your iPhoto library in the Pictures folder, use Spotlight to search for the filename "Library.iPhoto".  The path to your iPhoto library should show up in the results list when you select this result. See this article for additional tips.

Note: The manual rebuild procedure does not preserve metadata such as album names, sorting, or comments. It may also introduce duplicates into the iPhoto library. After importing the photos you may want to reorganize and re-edit the contents of your new iPhoto library from within the iPhoto application.

Last Modified:
Helpful?

Additional Product Support Information

Start a Discussion

in Apple Support Communities
See all questions on this article See all questions I have asked
United States (English)