How to change profile folder name without rebuilding user profile from scratch?

32,418

Solution 1

Microsoft has an answer for this:

Both give the same information, in different ways. The important part is that renaming the profile's pathname requires an update to the registry HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList

Solution 2

Although everything here is correct, all of you are missing one very important thing:

THIS WON'T FIX THE PATHS OF ALREADY INSTALLED SOFTWARE THAT MAKES ENTRIES TO \USERS\USERNAME\APPDATA folder. All entries here remain pointing to old user profile name, this Will cause issues like "path not found" when uninstalling apps or while opening them. Besides you will get your Outlook profile corrupted and Good knows what else more. I ended up backing up the user's data, deleting the corrupted profile and recreating from a scratch a new profile for that renamned user, and restoring user's data.

I have found hundreds of websites with more or less same procedure to rename the user's profile folder but all of them missed what I mentioned. I can say the method Works very well if it is a newly created profile then you rename the users name inmediately: without configuring/installing anything prior to the renaming process, in this case this Works flawessly!

Trust me, I'm telling you by experience! I read a lot of tutorials and sounds more or less easy to do but it turned out a nightmare.

Solution 3

From: https://social.technet.microsoft.com/Forums/exchange/en-US/0a3a20fa-85d2-414e-aff2-267d5f2ca80c/rename-a-username-and-email-address-due-to-marriage-or-divorce

On the Attribute Editor tab [of the Active Directory Users and Groups -> Users -> (username) -> Properties] Look for the attribute named “objectSID’ and write that number on a piece of paper for later

...

[On the users machine login as Admin and] Rename the user profile folder:

Browse to C:\Documents and Settings\isingle Right-click on the folder, choose Rename Rename the folder to C:\Documents and Settings\imarried

Change the Profile Image Path in the Registry:

Start> Run> regedt32 Expand to HKEY_LOCAL_MACHINE \ SOFTWARE\ Microsoft\ Windows NT \ CurrentVersion \ ProfileList

Select the correct SID that you wrote down previously when you noted it from ADUC above In the right-pane, double-click the ProfileImagePath value and change the profile path to C:\Documents and Settings\imarried

Close Registry Editor, and restart Windows.

Solution 4

In addition to what's been answered here, there's an app out there called RegEditX that allows one to change registry entries in bulk. I used it to change my user name from, say, "Jos_Smith" to "JoeSmith". One very important note: in addition to changing "Jos_Smith" to "JoeSmith", you also need to change all entries of "Jos_Sm~" to "JoeSmi~". Those entries are mostly in the installation folder entries, i.e. where application store their installation files. Here's the link: http://www.dcsoft.com/products/regeditx/

Share:
32,418
Austin ''Danger'' Powers
Author by

Austin ''Danger'' Powers

Updated on September 18, 2022

Comments

  • Austin ''Danger'' Powers
    Austin ''Danger'' Powers almost 2 years

    A user at work recently got married and has requested for her domain username to be updated to reflect her married name. She uses a Windows 7 PC on a Windows 2003 domain.

    I know that I can simply update the user's name in AD and this will probably suffice for the most part; however, the folder structure on her PC will not reflect this change, which could cause confusion for her further down the line:

    c:\users\old-username\
    

    Besides completely re-creating the user's profile on this PC from scratch, how can I correct the misspelling in the user's profile?

    • Michael Frank
      Michael Frank about 9 years
      You've got a couple good answers here, but depending on the way your new users are created it's probably much easier to create a completely new profile, mirror the AD access and then migrate the appropriate folders (like Desktop, Favourites, etc) to the new profile folder. This prevents issues like the below where you need to deal with registry entries and SIDs.
    • Austin ''Danger'' Powers
      Austin ''Danger'' Powers about 9 years
      Actually, I'm leaning towards doing it the registry way suggested in the answers as that just involves changing one or two registry keys that I'm already familiar with. I'll report back soon after I try it. Rebuilding a profile from scratch is going to lose a lot of user profile customizations and will increase the work required by me (and most likely irk the user one way or another!)
    • Austin ''Danger'' Powers
      Austin ''Danger'' Powers about 9 years
      So there was no reason to create the user profile from scratch - I just did the registry fix and it was a) very quick and easy and b) ensured 100% of user customizations persisted. Thanks everyone!