Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My new work computer's command prompt automatically brings up "H:\>" when I open it. Is there a way for me to change that safely? Specifically, to "C:\foo\bar\Something Else"? I found the method of changing the Autorun value through Google, but it came with a warning that it "might affect the functionality of batch scripts."

Bonus note: I was originally getting at this issue in this question, but I didn't ask very directly. The answer I ended up accepting was really good, so I wanted to leave it there.

share|improve this question
up vote 5 down vote accepted

The command prompt automatically starts in the Home Directory specified in your user profile.

A "workaround" to avoid messing with scripts and such is to create a new shortcut to cmd.exe.

  • Create a new shortcut to %systemroot%\system32\cmd.exe
  • Once the shortcut is created, right-click and select Properties
  • In the Shortcut tab, set the "Start in" field to the path you want to start in, ie, C:\foo\bar\Something Else
  • Click OK and try your new shortcut!
share|improve this answer

First method : Execute a change-directory command when cmd starts

From "How to change the default startup directory for Command Prompt?":

Click Start, Run, and type Regedit.exe.
Navigate to the following branch:

HKEY_CURRENT_USER\Software\Microsoft\Command Processor

In the right-pane, double-click Autorun and set the startup folder path as its data, preceded by "CD /d ".
If Autorun value is missing, you need to create one, of type String in the above location.

Example: To set the startup directory to F:\Windows, set the Autorun value data to "CD /d F:\Windows".

Second method : Change user's home folder

Right-click "My computer" and choose Manage.
Select "Local users and Groups" and then Users.
Double-click the user in question and go to the Profile tab.
Set in "Home folder" the required directory as the value of "Local path" and do OK.

share|improve this answer
you need to logoff and back for changes to take effect, thanks for the tip. – yoshco Sep 3 '13 at 6:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .