Run any Windows program as a different user

Sometimes you might need to run a program as a different user to the one you are logged in as and thankfully Windows has a command line tool for that!

Known as “Runas”, this little gem has been around since Windows Vista and will allow you to launch any program with the permissions of another user on your computer.

runas /user:administrator "C:\path\to\file.exe"