Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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

I tried using at first a combination of xcopy and del, but del kept failing.

xcopy creates directory if it doesn't yet exist.

The other option is to use MKDIR but it does not work inside a batch file?

MKDIR "C:\stuff"

Any ideas why this is not working inside .bat/.cmd file??

It works fine from a command prompt.

share|improve this question
What error do you get? – Paul Jul 26 '13 at 3:13
Provide real example so we can reproduce the problem. – Vlastimil Ovčáčík Jul 26 '13 at 6:13

Try using md instead of mkdir

md "c:\stuff"

This has always worked for me.

share|improve this answer

In Windows Vista, 7, and 8, there is a feature called User Account Control. To make a new folder in just any location, you need to be running an "elevated command prompt," which is running Command Prompt as an administrator.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.