How to let windows automatic execute a bat file after startup

How to let windows automatic execute a bat file after startup?

Who is Participating?
g00334120Connect With a Mentor Commented:
One way is to place the batch file in the startup folder for windows. Which version of windows are you running?

Another way is to go to the following key in the registry:


Create a new key there of type String.

For its data value, type in the full path to the to bat file


Every time windows loads up, this batch file will run.
easier would be to put into autostart folder.
Just open windows explorer (start->run: explorer)
and copy your batch to the folder autostart
the location of autostart depends on which windows version you are using: in win9x was in windows\menu
in win2000 xp it is better you put in default user folder since it wil start for all users, if you want for one user you put it in in the user folder like:
c:\Documents and Settings\Doctor\Startmenu\Programs\autostart
so just put the batch in this folder.
Michael PfisterCommented:
Both methods above require that a user logs on. If this is a problem you can use the Task Scheduleder and tick the "At System Startup" option.
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

autostart?  Never saw that in English versions of XP/2k, anyway...might be the case in other languages.

location here is:

C:\Documents and Settings\<username>\Start Menu\Programs\Startup

Also, I believe placing it in "Default User" will only take effect for users created after the changes were made (It's like a template).
Placing your .bat in "All Users" will take effect for everyone immediately upon next login by anyone.

C:\Documents and Settings\All Users\Start Menu\Programs\Startup
A really nice and neat way of doing this is to use: and create a service from your batch file.  This will then execute the batch file whenever you start the machine, even if a user doesn't log in.

I recommend a split between myself and JamesHarrison.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.