Move to a new PC

From MozillaZine Knowledge Base

This article was written for Thunderbird but also applies to Mozilla Suite / SeaMonkey (though some menu sequences may differ).

Mozilla applications don't store your data in the program directory. They store it in a "profile" directory instead in order to make it easier to upgrade or re-install without worrying about losing your data. For example, if you're using Thunderbird your profile has all of your mail, address books, settings, saved passwords, add-ons etc.



The simplest solution if you're using Windows would be to use Mozbackup to backup the complete profile, copy the *.pcv file it creates to the new PC, install the Mozilla application and Mozbackup on the new PC, and then use Mozbackup to restore the profile. Don't delete anything on your old PC until you've verified you can use the moved profile.

The simplest way to copy the *.pcv file between the two PCs would be to use a USB flash drive (aka thumb drive). A *.pcv file is a renamed .zip file so its compressed.

Use Mozbackup 1.5.2 Beta 1 (there is also a download link for it in the News section) rather than the version available at the normal download link. Mozbackup is no longer being maintained. Version 1.5.1 usually works fine but a few users have had problems where it doesn't backup everything it is supposed to. The beta doesn't seem to have that problem.

If you have problems restoring the profile see the MozBackup article. Mozbackup is extremely popular and usually works without a problem, but due to its popularity there is plenty of experience in how to deal with problems. If you can't find the Mozbackup download and you're using Firefox, look in Tools -> Options -> General ->Downloads to see where it downloads files by default. See this article for some alternatives to Mozbackup.

Mozilla applications such as Thunderbird, Firefox and SeaMonkey use a Profiles.ini file to find profiles. So just copying a profile to the default location won't work. You either need to use an application that updates profiles.ini for you like Mozbackup, edit it yourself, use the profile manager to update profiles.ini (by telling it to create a new profile at the location where you copied the old profile) or copy the profile over an existing one that is already listed in profiles.ini. One advantage of Thunderbird using profiles.ini is that you can store the profile almost anywhere (just don't store it in your applications program directory).

If you don't want to use Mozbackup you could copy the old profile to the new PC and follow the instructions in Move your profile instead. Help -> Troubleshooting Information -> Open Folder will open your systems file manager at the profile if you don't know where it is stored.

Not using Windows

If you're not using Windows see Moving your profile for another solution. One quick and dirty solution would be to start the Mozilla application on the new PC and immediately exit. That will create a stub of a profile (if you didn't have a profile on that PC). You could then find its location ("help -> troubleshooting information -> show folder" will open your systems file manager at that directory) and copy the contents of your old profile over it. That is described in more detail here . However, we've learned from helping people in the forums that there are a lot less problems if you use a not well known feature of the profile manager to tell the application where the profile is instead. That is described here.

Quick and Dirty without using Mozbackup

This assumes you haven't installed Thunderbird on your new PC yet and don't trust Mozbackup. If you have already run Thunderbird on the new PC make certain that a copy of any new mail you downloaded using it is either still on the mail server or in the old profile, and in step 3 just launch Thunderbird instead.

1. Run Thunderbird on your old PC. Use Help -> Troubleshooting Information -> Show Folders to launch windows explorer (or whatever file manager your system uses) at your current profile.

2. Copy and paste (just) that profile to a flash/USB drive .

If your profile was at C:\Users\JohnSmith\AppData\Roaming\Thunderbird\Profiles\xyz.default you would only copy xyz.default. Don't copy Profiles\xyz.default. Don't delete anything until you've verified you managed to use that profile on the new PC.

3. Install Thunderbird on the new PC. Run it. It will launch a "new account wizard" since it can't find any profiles, create a stub of a profile, create a profiles.ini file, and update profiles.ini file to point to that stub of a profile. That profile has nothing useful yet, but Thunderbird knows how to use it. Abort the new account wizard. Don't exit Thunderbird yet.

4. Use Help -> Troubleshooting Information -> Show Folders to launch windows explorer (or whatever file manager your system uses) at your current profile.

5. Delete the contents of that profile directory. Do NOT delete the actual directory.

6. Copy and paste the contents of the old profile on your flash drive into the profile on your new PC using windows explorer (or whatever file manager your system uses). If your old profile was at ...\xyz and you created a xyz subdirectory in the new profile when you copied the contents of the old profile you did it wrong. Delete the contents of the new profile and try again.

If you run into problems either delete the profiles.ini file for Thunderbird (be careful you don't delete the one for Firefox by mistake) on the new PC and try again, or see the "Nothing you do works" section in Moving your profile.

Copy and paste just a few files instead

This explains how to copy the personal address book and the mail folders for a single POP account to the new PC if for some reason you don't want to copy the entire profile. This is actually more work than using Mozbackup but might be easier for some people since it doesn't have any external dependencies and all of the instructions are in one place.

1. Start Thunderbird on your old PC.

2. Press the Address Book button.

3. Select your personal address book, and use Tools -> Export to export it as personal.ldif (a .LDIF file).

4. Copy personal.ldif to a storage location such as a USB flash drive.

5. Find your account in Tools -> Account Settings. Select Server Settings. Look at the bottom of the pane for "Local Directory", next to a browse button. That specifies where the mail folders (they're stored as mbox files) are stored for your account. They are named after the folder, and have no file extension. For example your inbox is "inbox.", not "inbox.msf" or "inbox.sbd". If you're using a global inbox look in the Local Folders pane instead.

6. Use Windows Explorer (or My Computer) to go to that directory.

7. Copy the mail folders you want to a storage location such as a USB flash drive.

8. Start Thunderbird on your new PC.

9. If you don't have an account let it run the account wizard, and create your account.

10. Use Tools -> Import -> Address Books -> Text Files to import personal.ldif. That will create a new address book. Drag and drop its contents to the personal address book and then delete the imported address book.

11. Copy the mbox files either to the accounts Local Directory or Local Folder's Local Directory. You can find their location the same way (Tools -> Account Settings, and find the Local Directory either in the accounts Server Settings pane or in the Local Folders pane).

Its easy to modify this if you have more than one POP account. If you have a IMAP account the messages should still be in remote folders on the IMAP server, so there is no need to copy them.

PC died

If you are moving to a new PC because your PC died, if the hard drive still works you can attach it to the new PC and then move the profile per Move your profile. If you can't install the hard drive within the PC as an additional drive you could buy an inexpensive adapter to use it as a external hard drive.

If you are using Windows the main problem will be finding where the profile was stored. Typing in %APPDATA% in Start → Run won't tell you the profiles location anymore because that uses the profiles.ini file for your current Windows account, not the one on the old hard disk. You will need to remember your old Windows username and browse the ..\Documents and Settings\<old windows username>\Application Data directory tree on your old hard disk to find it. The profile will have a prefs.js file (your settings), a abook.mab file (personal address book) and a Mail subdirectory (among other things) in it. If you had more than one profile you could either guess which one was the current profile by comparing the date the prefs.js file was updated, or look in the old profiles.ini file to see which profile was the default profile. The old profiles.ini file will specify the wrong drive but the rest of the path to the profile(s) will be accurate.

See the links in "See also" (below) for an article on how to find your profile. It is written for somebody whose profile is installed on their boot drive but some of it such as how to view hidden files and folders will be useful.

Moving from Windows to OSX or Linux

The profile contains a prefs.js file that stores both absolute and relative path names for where each account stores its mail. A relative path name means you don't specify the full path, you specify its location relative to where the profiles.ini file is stored.

If you move a profile between two different versions of Windows the syntax is identical. However, if you move it between dissimilar operating systems the syntax is incompatible and may break the absolute version of a path. For example, Linux has no concept of a drive C:. Normally this is harmless since Thunderbird prefers to use the relative version. However, if this causes a problem (most of the folders for an account aren't visible, and your inbox looks empty) find the local directory setting at the bottom of the Account Settings page, and use the "Browse" button to update its location. Normally it points to a directory named after the mail server used by that account, unless you using a global inbox. In that case it points to the Local Folders directory in the profile.

Troubleshooting if you moved just part of the profile

Its recommended that you move the entire profile, rather than just part of it (such as Local Folders). Too often when somebody does that either Thunderbird doesn't recognize the profile (causing it to automatically run the new account wizard) or Thunderbird mis-interprets files in the root of the profile such as abook.mab as mail folders because the overall layout of the profile is messed up. Its much safer to move the entire profile, and if you want to get rid of some files, do that afterwards.

If Thunderbird runs the new account wizard try running Thunderbird with a command line argument to specify the profiles location. See Running_from_a_USB_drive_-_Thunderbird for how to do that. That will let you verify the profile is good, so that you can deal with problems with profiles.ini afterwards.

If Thunderbird starts mis-interpreting files as mail folders, make certain that you have a Mail subdirectory that contains a Local Folders subdirectory, and additional subdirectories for each POP account. Compare the directory structure to Files and Folders in the profile

See also