Windows 10 Automatic PC setup script via .exe on USB

DylanH

New Member
Joined
Apr 24, 2023
Hello, I work as the sole member of the IT department of a small business. I spend much time replacing dead storage drives or setting up new workstations. I was wondering if there was a way I could write a script that I could put on a USB drive that I could plug into a PC with a fresh installation of Windows. It would automatically set up everything the way our users require (install specific programs, change the default browser, change various settings, create users, run updates, etc.) Obviously, I'd have to open the USB drive in file explorer and run the .exe but that's a lot easier than manually going through everything and setting it up. Now better yet... if there's a way I can somehow add this to the installation media or something like that, that'd be even better. I'm not asking someone to write this script for me (Although that'd be nice lol), I'm just asking to be pointed in the right direction. I'm a very technically inclined person and learn very quickly but as of right now, I don't know how to do this and my search hasn't gotten me very far. We're currently transitioning from Windows 10 to Windows 11 as we replace our PCs (the old ones aren't W11 compatible but the new ones are) so I'll need either one script that works for 10 and 11 or two separate scripts that work for each Windows version. Any help is appreciated! Questions are more than welcome. Thanks!
 
There are a lot of solutions out there for this. The more hands off are going to be expensive like SCCM and probably not appropriate for a small business. There are free solutions as well, they do require your time to build out and require some scripting experience.

You'll want to break out your process into three smaller processes.
  1. Automating Imaging of Machines
  2. Installing Software
  3. Migration of User Data
If you have central authentication in place (such as AD) and a file server the process will be a lot easier, or if you have just a file server that will help a lot.

For imaging you have either WDS (Windows Deployment Services) semi depreciation for this and MDT (Microsoft Deployment Toolkit) Microsoft Deployment Toolkit documentation preferred to help you build a golden image and help you auto deploy it to new systems.
[NOTE: You will need to perform offline updates to the image periodically to keep it current, or don't and spend more time patching systems after imaging]

Software Installation
With out SCCM this would likely be a self made script with either local (USB) copies of installers or on a file server

Migration of User Data
USMT will be your friend here User State Migration Tool (USMT) overview - Windows Deployment
Be warned you may be learning how to modify the XML config file a lot to meet your needs (assuming software is pretty standard accross machines), again if you have a file server you could create a script that does a periodic backup of machines and then you can simply push that back to the new machine (good option in case of system failures as well)
 
Back
Top Bottom