These days most PCs can boot from USB, so you need no DVD drive any more to install Windows 10. Installing Windows 10 from a USB flash drive is much faster than optical drive setup. Here is how you can transfer your Windows 10 setup to a bootable USB stick.
I assume that you already have an ISO image with Windows 10.
You will need to erase all data from the USB flash drive before proceeding, so please make a backup of your important data.
If you are running Windows 8 or Windows 10, double-click your Windows 10 ISO to open its contents. It will appear as a virtual DVD drive inside This PC in File Explorer.
If you are running Windows 7, use the free and open source 7-zip archiver or install Virtual CloneDrive by RedFox. Virtual CloneDrive is a freeware app which creates a virtual drive in which can mount ISOs.
How to Install Windows 10 from a Bootable USB Stick
Open Command Prompt as Administrator.
Type or copy-paste the following command:
diskpart
Diskpart is a special console tool which comes bundled with Windows 10 by default. It allows performing all disk management operations from the command line.
Connect your USB stick and type or copy-paste the next command.
list disk
It will print a list with all your disks, including the currently connected USB stick. Note its number in the output.
In my case, it is Disk 1.
To proceed with your USB drive, you need to select it in Diskpart. This can be done with the following command.
sele disk #
Replace ‘#’ with the number of your USB stick drive.
Warning! The next command will erase all data from the drive, so ensure you have no important files stored on the drive.
clean
The next command will create a new partition on your drive so you will be able to put Windows 10 Setup files.
crea part prim
Format this partition with the next command.
format quick
Next, type the following command:
active
This is to allow your USB stick to be able to load some bootloader.
Type ‘exit’ to leave the Diskpart app.
Copy all files from the Windows 10 ISO image to the USB stick.
Now you need to write a bootloader to your USB stick. Suppose your mounted ISO image has the drive letter, D: in the This PC/Computer folder, and your USB stick has the drive letter E:
Then you need to type the following command at the elevated command prompt:
D:\Boot\Bootsect /NT60 E: /force /mbr
This will write the NT6 boot sector to your USB stick. Replace the letters in my example with the appropriate letters in your OS.
Restart your computer and boot it from your USB drive. Now you can install Windows 10.