# Is it possible to use Boot Camp with Windows 10 from an external HDD?

I need to run Visual Studio on my MacBook Pro and I need Windows to do that. The easiest and well known way to install Windows on a Mac is by running the Boot Camp app on the Mac and let it do what's necessary. The problem is that I don't want to partition the Internal SSD so the remaining option is to install Boot Camp Windows 10 on an External Drive and boot it every time I need it by plugging in my external USB 3.0 HDD. Is this achievable?

Here's an updated procedure for Windows 10, based on orkoden's excellent answer.

I tested this process on a MacBookPro11,1 running OS X 10.11.5 (15F34). Throughout the process, directly connect all devices to your Mac. I found that certain operations failed more frequently if I used the USB hub in my monitor.

In addition to the external drive that will host your Windows installation (the "destination drive"), you will need another USB drive (the "driver drive") to temporarily store the Boot Camp drivers.

I used these parts:

• Destination drive: Samsung T3 Portable 500GB USB 3.0 External SSD (MU-PT500B/AM)
• Driver drive: SanDisk Extreme 32GB USB 3.0 Flash Drive (SDCZ80-032G-GAM46)

Here are the steps:

1. Install VMware Fusion 8.1.1 from VMware's site
2. The non-professional free evaluation version is sufficient
3. VMware Fusion 7.1.3 couldn’t connect my external USB disk to my Windows VM
6. I chose Windows 10, English, 64-bit
10. Prepare the driver drive.
1. Run diskutil list to determine the device name. In my case, the device name was /dev/disk2.
2. Erase the disk using diskutil eraseDisk fat32 DRIVERS MBR /dev/disk2
3. Open Boot Camp Assistant
1. In "Introduction", click "Continue"
1. Uncheck "Create a Windows 7 or later version install disk"
3. Uncheck "Install Windows 7 or later version"
4. Click "Continue"
4. In "Save Windows Support Software", choose the driver drive, and click "Continue".
5. Wait for the process to complete.
4. Eject the driver drive: diskutil eject /dev/disk2
5. Disconnect the driver drive.
11. Prepare the temporary Windows VM. We’ll use the temporary Windows VM to write the disk image to the destination drive. In VMware Fusion:
12. Create a new VM:
1. File > New
2. In "Select the Installation Method", choose "Install from disc or image", and click "Continue".
3. In "Create a New Virtual Machine", choose "Use another disc or disc image…", locate Win10_1511_1_English_x64.iso, and click "Continue".
4. In "Microsoft Windows Easy Install", uncheck "Use Easy Install", and click "Continue".
5. Click "Finish".
13. Start the VM and complete Windows Setup. The settings don’t really matter, because we’re just using this VM to write the disk image.
1. Choose "Next"
2. Choose "Install now"
3. Choose "I don’t have a product key"
4. Choose "Windows 10 Pro"
5. Choose "I accept the license terms"
6. Choose "Custom: Install Windows only (advanced)"
7. Choose "Drive 0 Unallocated Space" and click "Next"
8. Choose "Use Express settings"
9. Choose "I own it"
10. Choose "Skip this step"
14. Install the Automated Installation Kit:
1. From the "Virtual Machine" menu, choose "CD/DVD (SATA)" > "Choose Disc or Disc Image...". Select KB3AIK_EN.iso.
2. From the Start menu, choose "File Explorer", and then "This PC". Double-click "DVD Drive (D:) KB3AIK_EN".
3. Choose "Yes"
4. Choose ".NET Framework Setup"
2. After installation completes, choose "Close"
5. Choose "Windows AIK Setup"
1. Choose "Next"
2. Choose "I agree"
3. Choose "Next"
4. Choose "Next"
5. After installation completes, choose "Close"
15. Prepare and image the destination drive:
1. From the Start menu, choose "All apps". Choose "Microsoft Windows AIK". Right-click "Deployment Tools Command Prompt". Choose "More", then choose "Run as administrator". Choose "Yes".
2. Prepare the destination drive:
1. Run diskpart
2. Plug in the destination drive. In the "Choose where you would like to connect " prompt, choose "Connect to Windows"
3. Run list disk to determine the disk number of the destination drive. In my case, the disk number was 1.
4. Run: select disk 1
5. Run: clean
6. Run: create partition primary
7. Run: format fs=ntfs quick
8. Run: assign
9. Run: active
10. Run: list volume
11. Note the drive letter for the selected volume (marked with a *); this is the drive letter of the destination drive. In my case, the letter was "E".
12. Run: exit
3. Image the destination drive:
1. From the "Virtual Machine" menu, choose "CD/DVD (SATA)" > "Choose Disc or Disc Image...". Select Win10_1511_1_English_x64.iso.
2. Run: imagex /check /verify /apply d:\sources\install.wim "Windows 10 Home" e:
• For Windows 10 Pro, use "Windows 10 Pro"
• For Windows 10 Education, use "Windows 10 Education Retail Technical Preview"
3. Run: bcdboot e:\windows /v /s e:
4. Run: shutdown /p
5. Quit VMware Fusion
16. Restart into Windows to complete installation
1. Restart the Mac while holding the Option key
2. When the startup disk list appears, use the arrow keys to choose Windows. Complete Windows Setup. If Windows restarts during Setup, restart again while holding the Option key to return to Windows.
3. Insert the driver drive. Open the Start menu, choose “File Explorer”, choose “DRIVERS (E:)”, open the “BootCamp” folder, and open “Setup”. Complete the installation.

Windows is now installed and ready.

• To restart into OS X, click the Boot Camp icon in the notification area and choose “Restart in OS X…”.
• To restart into Windows, open “System Preferences” from the Apple menu, choose “Startup Disk”, choose “BOOTCAMP”, and then choose “Restart…”.
• To choose an OS at boot time, hold down the Option key.
• Missing a small step above: Run: select disk 1 Run: clean Run: create partition primary Run: select partition 1 Run: format fs=ntfs quick – chrishiestand May 23 '16 at 1:27
• Thanks for verifying this works for you. Your steps are pretty much the same as @orkoden's above but I do like the /check /verify addition to the imagex command. Unfortunately I'm unable to reproduce your success tonight. I may have a problem with my USB3 -> sata adapter (Thermaltake BlackX 5g) - or perhaps it's an issue with the USB3 controller on my MBP. I keep losing the connection to the disk both when I boot Windows and in Parallels/VMWare. In any case, I'll need to borrow some known good equipment before I can figure out if this works. – chrishiestand May 23 '16 at 7:30
• I tried again on an external USB drive and it worked. So it was either my SSD or (more likely I think) the Thermaltake BlacX 5G usb3 adapter that was dropping the connection – chrishiestand May 25 '16 at 5:41
• @chrishiestand and Alex: I downloaded the Windows 10 Assessment and Deployment Kit and substituted the command Dism /apply-image /imagefile:D:\sources\install.wim /index:1 /ApplyDir:E:\ /CheckIntegrity for your posted command imagex /check /verify /apply d:\sources\install.wim "Windows 10 Home" e:. This substitution worked for me. The command Dism.exe is the new replacement for the deprecated imagex.exe command. This was not the only change I made to your procedure, but it was the most significant. – David Anderson May 25 '16 at 21:46
• When trying to change the startup disk to my hard drive, it states You can't change the startup disk to the selected disk; The bless tool was unable to set the current boot disk. I am using a volume on my external hard drive instead of the whole disk. Used imagex.exe. Anything? I used Disk Management to reformat the partition. Is the GUID partition map the problem, and if so, how do I change it? – Brick Sep 29 '16 at 13:30

Yes, you can do it. The instructions are originally for Windows 8. Some terminal commands might be a little different for Windows 10.

You will need :

1. Windows 10 x64 ISO file
2. a running Windows installation real or virtualised
3. a blank external hard drive
4. Apple Bootcamp drivers (obtained from the BootCamp setup) on USB key
5. Microsoft AIK

## Format and prepare external drive

1. launch the CMD line tool (click on the Start menu, in the search bar type CMD, then launch it)
2. type DISKPART
3. type LIST DISK It will list all drives (DISK 0 ; DISK 1; DISK # ; etc...)
4. Choose the disk you want Windows installed onto and type accordingly SELECT DISK # (# being the number of the disk you want to use (e.g. SELECT DISK 2)
5. Type LIST DISK again, and you will see a * in front of the disk to be erased.
6. Type CLEAN
7. Type CREATE PARTITION PRIMARY
8. Type SELECT PARTITION 1
9. Type ACTIVE
10. Type FORMAT FS=NTFS QUICK
11. Type ASSIGN
12. Type EXIT or close the window

## Install Windows with AIK

1. install AIK
2. Mount the Windows 10 ISO image as a drive. VMWare etc. can do that, otherwise use a tool like PowerISO.
3. Note your drives letters before proceeding. Change the letters for your system accordingly. - Drive letter for Windows ISO? Here E: - Drive letter for empty hard drive? Here G:

4. Open CMD tool as an Administrator: click on the Start menu, type CMD, right click and select Run as Administrator

5. Type C:\Program Files\Windows AIK\Tools\Amd64\imagex.exe /APPLY E:\sources\install.esd 1 G:\ (change the letters to fit your setup)
6. Make the USB Drive Bootable. Type BCDBOOT G:\WINDOWS /S G:

## First boot and driver installation

1. Plug the external hard drive into your Mac.
2. Start your Mac and hold the ALT (⎇) key to choose the Windows Drive you just installed.
3. Windows will boot, and then will reboot the computer. At the boot chime hold ALT key and again choose the Windows drive.
4. Once on the Windows desktop appears, plug in your Apple Windows Drivers USB keydrive and install the Bootcamp drivers.

After the installation, reboot Windows. Hold ALT again at startup to choose the Windows drive.

• Would you recommend doing this on a 3.0 USB Drive? As I said I need this just to use Visual Studio – Mattia Righetti Dec 3 '15 at 14:32
• USB 3.0 is preferable to USB 2.0. An SSD is preferable over a hard drive. – orkoden Dec 4 '15 at 10:24
• Instead of CREATE PARTITION 1 you should type CREATE PARTITION PRIMARY – leolobato Feb 23 '16 at 11:43
• Make sure your partition is the first on the disk, if not definitely set as the primary. I started off trying to use a 2nd partition, so I assume once you've got it working, you could resize and add a 2nd partion. Not sure how I could have made the 2nd primary, without starting again. Also, when rebooting osx, it will miss the usb drive the first time, so you have to power down, and then boot again, holding alt. Something like it doesn't do a full reboot, and so doesn't pickup the drive. After that it worked, but then auto updated gfx drivers, and seemed to brick the install. Turn off! – Chris Barry Jul 14 '16 at 8:49
• If you need to do this with the new tool, after imagex, its Dism /apply-image /imagefile:N:\Images\my-windows-partition.wim /index:1 /ApplyDir:C:\ technet.microsoft.com/en-us/library/hh824910.aspx and the image file is install.esd not install.wim – Chris Barry Aug 12 '16 at 16:37

# Process for 2015- MacBooks (EFI installation)

You will need access to a working Windows 10 installation. See other answers to install a virtual machine.

In Mac OS:

1. Run Boot Camp Assistant to put the Windows drivers onto a separate USB stick
3. Transfer the ISO to your Windows installation.

In Windows:

1. Install Windows ADK, uncheck all alternatives except "Deployment Tools"
2. Double click the Windows ISO to mount it as a drive
3. Plug in the external USB drive.
4. Open command prompt and run the following:

Formatting the drive:

diskpart

list disk

select disk 1 (the id of your external drive)

clean (warning: this will erase everything on the drive)

convert gpt

create partition efi size=200

format quick fs=fat32

assign letter=s

create partition msr size=16

create partition primary

format quick fs=ntfs

assign letter=w

exit

Installing Windows:

dism /apply-image /imagefile:D:\sources\install.wim /index:1 /ApplyDir:W:\ /CheckIntegrity (D is the letter of the windows installation drive, W is the external drive's NTFS partition, Index 1 is for Windows 10 Pro, use 2 for Windows 10 Home)

Installing boot files:

bcdboot W:\Windows /s S: /f UEFI (S is the external drive EFI boot partition)

Done! Plug the drive into your Mac and restart holding down the Option key and you should see EFI Boot as an alternative, this is your Windows 10 installation.

Final step is to install the Boot Camp Windows drivers. Run setup.exe from the USB drive.

• Did you try this on a 2016 rMBP or works only on 2015 models? – kikettas Jan 15 '17 at 0:19
• I have a mid 2015 rMBP, but it should work for newer MacBook models too. – Simphax Jan 15 '17 at 13:40
• I tried this just now on my 2016 MacBook Pro (13" with Touch Bar). Neither the Trackpad, nor the keyboard (including the Touch Bar) were recognized during setup so I had to use an external keyboard to set it up. Also it hung quite a long time at 95% during the dism-step. Just be patient! – bluefirex Jan 29 '17 at 14:33
• Simple, Great ! I just had Windows 10 Pro w/o intall.wim file so just export it from eps and done! Working like charm and i do not have to have external keyboard.. But i suggest to download drivers from Boot Camp! Thanks again! – liborza Feb 9 '17 at 6:25
• @Gripsoft I've updated the answer :) – Simphax Mar 26 '17 at 8:29

This is basically Alex Lambert's answer from above with a a few updates. You don't need the Automated Installation Kit, you can use commands which are in the ISO. And the install.wim file is no longer included in the ISO so I've added the steps to convert the install.esd into install.wim.

Here are my updates to his post above:

You don't need AIK so delete step 3, step 5.3, and step 6.1.

Here is the updated 6.2 with chrishiestand's correction.

6.2

1. Prepare the destination drive:
2. Run diskpart
3. Plug in the destination drive. In the "Choose where you would like to connect" prompt, choose "Connect to Windows"
4. Run list disk to determine the disk number of the destination drive. In my case, the disk number was 1.
5. Run: select disk 1
6. Run: clean
7. Run: create partition primary
8. Run: select partition 1
9. Run: format fs=ntfs quick
10. Run: assign
11. Run: active
12. Run: list volume
13. Note the drive letter for the selected volume (marked with a *); this is the drive letter of the destination drive. In my case, the letter was E.
14. Run: exit

Do step 6.3 to mount the ISO to the VM.

Here's my update to step 6.4:

1. You’ll need to convert the install.esd file to install.wim.
2. Copy d:\sources\install.esd to somewhere on your hard drive (I used the Documents folder).
3. Copy d:\sources\dism.exe to the same directory.
4. Get details about what images are inside the ESD file with the following command. We'll need to take note of the index No. that we need by running:

dism /Get-WimInfo /WimFile:install.esd

5. Take note of the index of the particular OS version you'd like to install (in case the esd has many images inside it) the number is what is inserted in the SourceIndex. I am choosing index 1 (Windows 10 Professional)

dism /export-image /SourceImageFile:install.esd /SourceIndex:1 /DestinationImageFile:install.wim /Compress:max /CheckIntegrity**

6. After the progress reaches 100% and integrity checks are through, you'll have a WIM file alongside the ESD file. Run:

Dism /apply-image /imagefile:install.wim /index:1 /ApplyDir:E:\ /CheckIntegrity**


(thanks David Anderson for the DISM command to write to the destination drive)

Continue on from step 6.5 and everything should work great.

I really appreciate everyone posting as it got me very close and was able to figure out the couple other steps to get this working and wanted to post them here to help the next person trying this process.

It is very simple. If you have Parallels or VMWare simply get hold of two free Windows Utilities, miniTools (to format and set up the external drive) and WintoUSB.

Put the ISO of Windows 10 or 8.1 into the VM as you will need this when installing with WintoUSB. I've done this about 30 times already, and never had a problem. Using miniTools is the hardest part and that is simple once you figure it out.

It's best to format the new drive with the Mac as ExFAT first. Once you mount this in Parallels and run miniTools simply make the first partition (the small one you will see) Fat32 and make it primary and Active.

The second large partition make NTFS and primary also.

Once this is done WintoUSB is simple to use, select the ISO then the new external and check the EFI and main partitions as the destination.

That's it. I run Paragons NTFS utility on my Mac so I can write to an NTFS disk this way I can copy all the things I need such as Bootcamp drivers, AMD drivers are whatever from the Mac but if you just boot (hold option on start up) to the new disk it will install drivers in Windows itself.

I bought Windows 10 from Amazon (Home Edition) and every one of these I make is automatically authorized as licensed by Microsoft without any problem. The caveat is only to the same Mac (in my case a new Mac Pro).

BTW I can do all this above with El Capitan and macOS Sierra (I have a dev account at Apple).

• I just installed Windows 10 on an external drive using WinToUSB, and it was a snap. I'm glad among these very long, lengthy and probably difficult procedures someone has mentioned the easy way. (The downside to this method, though, is that you don't have a Windows recovery environment. That may be a dealbreaker for some. I found other ways of backing up my windows system to get around it.) – GuyGizmo Feb 23 '18 at 17:51

Start From Scratch & Please Follow Step By Step For the best use of these steps , i suggest you google each one before you start !! aka gather some info (Hardware Requirements).

1. Windows Computer installed and working (XP/2000 -Vista - 7 - 8 - 10 -VM).
2. Obviously a Mac computer with OS X10.10 and above
3. External Hard-Disk 32 Gb or More .
4. 4GB USB Key . Software Requirements :- • Files To Download On Windows
8. gdisk-1.0.1.pkg (LINK) YOU CAN DO THE STEPS FROM 1 TO 4 ON WINDOWS AND ON MAC IN THE SAME TIME -------------------------------------------------------------------------------- On WINDOWS :
9. Open MediaCreationTool
10. Choose CREATE INSTALLATION MEDIA FOR ANOTHER PC
11. Choose language and edition but it must be 64-bit
12. Save to ISO file ON YOUR PC ( Over 3 GB to download so you can follow with the next steps you still have sometime ! ) .
13. Plug in your External Harddisk (where you wish to install Windows.)
14. ON keyboard press and hold Window sign and the letter R (will open Run)
15. Type DISKPART (now it will open a cmd) next steps in cmd
16. Type list disk
17. Type select disk # (replace # with your external hard disk number that you got from the step above)
18. Type clean (when done you can close)
19. Right Click on your computer icon and select Manage.
20. On the left panel click on DISK MANAGEMENT "will take sometime to show also if it tells you to initialize choose gpt "
21. Find your external hard disk
22. On the DISK number right click and convert to gpt
23. now on the free space create a first partition with 500 MB and format to FAT32 name it EFI
24. Format the the rest of the free space to NTFS and name it OS
25. when done close everything you opened (clear view to desktop) .
26. Open WinToUSB Enterprise with administrator privileges.
28. Choose the External hard disk you just formatted .(must see and choose EFI if you did not see it that means you didnt format the hard disk or maybe still no converted to gpt google around)
29. Choose your desired Operating System.
30. Install and wait until its Done. -------------------------------------------------------------------------------- On MAC :
31. Open boot Camp app from your mac
32. Choose only to download latest media "basically uncheck all but check the second option ".
33. Save it to the USB KEY (Mentioned in Hardware Requirements above) .
35. Unplug USB KEY when done.
36. Open the file gdisk-1.0.1.pkg and install (Mentioned in Software Requirements above) .
37. Plug in your external HARD DISK .
38. Open terminal and run these commands and dont try to be geeky just follow these commands.
39. Type sudo gdisk /dev/disk0
40. Type p to view the existing partition table and verify you’re working on the correct disk.
41. Type x to enter the expert menu.
42. Type n to create a fresh protective MBR
43. Type w to save your changes and confirm the changes.
44. Type q to exit GPT fdisk.
45. So basically p enter x Enter n Enter w Enter q Enter .
46. Now restart and hold the option key and choose the External Harddisk
47. it Might boot several times make sure you always hold the option key .
48. When installing is done plug in your USB key and install drivers.

Done :)

Found the following at eGPU.io Forum which works on my 2015 MBP, where the earlier answers failed to get the USB drive listed during boot up. Differences:

diskpart list disk select disk 1 clean convert gpt create partition efi size=200 format quick fs=fat32 assign letter=s create partition msr size=16 create partition primary format quick fs=ntfs assign letter=w exit

• Install Windows

dism /apply-image /imagefile:D:\sources\install.wim /index:1 /ApplyDir:W:\ /CheckIntegrity where D is the letter of the windows installation drive, W is the external drive’s NTFS partition, Index “1” is for Windows 10 Pro, use “2” for Windows 10 Home)

• Install the boot files

bcdboot W:\Windows /s S: /f UEFI (S is the external drive EFI boot partition)

• this fixed my problem on MacPro 2013. I had the You can't change the startup disk to the selected disk; The bless tool was unable to set the current boot disk. problem. – Almo Feb 25 '18 at 18:28

# These instructions only require the external drive and the Windows 10 iso.

## No flash drives, virtual machines, Windows kits (AIK or ADK), or any other third party tools are required.

These are the basic steps needed to install Windows 10 for an EFI boot, when the Boot Camp Assistant will not create the necessary installation partitions and/or the Windows installer will not allow you to select the desired installation partition.

I have made the following assumptions.

• You wish to install Windows 10 on the external USB 3 drive. I have tested these instructions using a USB 3 HDD and an iMac (21.5 inch, late 2013). The version of macOS was High Sierra 10.13.1. If you are using a thunderbolt drive, the procedure should be the same.
• In the output of command diskutil list, the external drive appears as disk1. If you have a different disk identifier, you will have to make the appropriate substitutions.
• This drive has a "Device Block Size" of 512 bytes. You can determine the size by examining the output from the command diskutil info disk1. If the size is 4096 bytes, I will have to modify these instructions.
• Your Mac can boot Windows using the EFI. This should be true for any Mac that officially supports Windows 10 according to Apple.

The Windows specifications are given below.

• Edition: Windows 10 Pro
• Version: 1709
• OS Build: 16299.15

Note: To get a better view of the images shown below, either click on an image or open an image in a new window.

1. Use the Boot Camp Assistant to download the Window Support Software. Look for the "Action" pulldown on the Boot Camp Assistant menu bar. On my Mac, these files were downloaded to the ~/WindowsSupport directory.
2. Create empty space on a drive. This space needs to be outside any APFS or Core Storage containers. If you want to use an entire drive, you can skip this step.
3. At the end of this free space, allocate about 10 GB for the installation files, followed by 600 MB of space for the Microsoft Windows Recovery Environment (WRE). I usually use the diskutil command to do this. Other combinations of commands or third party tools can also be employed. The UUID for 10 GB partition should be EBD0A0A2-B9E5-4433-87C0-68B6B72699C7. The UUID for the 600 MB partition should be DE94BBA4-06D1-4D40-A16A-BFD50179D6AC.

If you want to use the entire drive, then the entire drive can be considered free space, so the command below would be sufficient.

diskutil  partitiondisk  disk1  3  GPT  "Free Space"  "dummy"  R  FAT32  "WINSTALL"  10G  %DE94BBA4-06D1-4D40-A16A-BFD50179D6AC%  %noformat%  600M


Note: A FAT32 format automatically selects a UUID of EBD0A0A2-B9E5-4433-87C0-68B6B72699C7.

4. Format the 10 GB partition FAT32 with the label "WINSTALL". If you used the command given in the previous step, so you can skip this step.
5. If the 10 GB partition is not mounted, do so now. If you used the command given in step 3, the partition should already be mounted.
6. Mount the Windows iso file and copy the contents to the "WINSTALL" volume. You will need the use the cp command from a Terminal application window. Below is the exact command I usually use. If necessary, make the appropriate modifications.

cp  -Rv  /volumes/ESD-ISO/  /volumes/WINSTALL


Note: This command will take a while to complete. Be patient!

7. Copy the Windows Support Software to the "WINSTALL" volume. Below is the exact command I usually use. If necessary, make the appropriate modifications.

cp  -Rv  ~/WindowsSupport/  /volumes/WINSTALL

8. Use the command shown below to delete the AutoUnattend.xml file.

mv  /volumes/WINSTALL/AutoUnattend.xml  /volumes/WINSTALL/NoAutoUnattend.xml

9. Next, you need to boot from the volume where the Windows installation files reside. Hold down the option key immediately after restarting on your Mac. Release the option when the Startup Manager window appears. Select the icon labeled "EFI boot". Next, select the arrow below the "EFI boot" label.

10. Open a Windows Command Prompt window, by following the procedure outlined in this step. Below is an image of what is initially displayed by the Windows 10 installer. Select "Next".

In the image shown below, select "Repair your computer".

In the image shown below, select "Troubleshoot".

In the image shown below, select "Command Prompt".

The result should be the image shown below.

11. Use the command diskpart to finish partitioning disk1. The commands you need to enter are given below.

Note: Sometimes it can take a while for the diskpart command to produce the first prompt. Be patient.

diskpart
list  volume


From the output of the command list volume, determine the number for the volume with the label "WINSTALL". In this example, I will assume this number is 0. Your number could be different. The next command selects this volume.

select  volume  0


The commands below change the letter for the "WINSTALL" volume to T:.

remove
assign  letter=t


The next command lists all the partitions in disk1.

list  partition


From the output of the command list partition, determine the number of the parition with the type "System". In this example, I will assume this number is 1. Your number could be different. Also, determine the number of the parition with the type "Recovery". In this example, I will assume this number is 3. Again, your number could be different. The commands below change the drive letter for the "System" partition to S:.

select  partition  1
assign  letter=s


The next commands effect the "Recovery" partition. The proper attributes are set. Next, the partition is formatted NTFS and given the label "Recovery".

select  partition  3
gpt  attributes=0x8000000000000001
format  fs=ntfs  label="Recovery"  quick


The command given below creates the tiny 16 MB Microsoft Reserved partition.

create  partition  msr  size=16


Finally, the commands below create the partition for the Windows operating system. This partition is allocated all remaining contiguous free space. The partition is formatted NTFS, given the label "BOOTCAMP" and assigned the drive letter W:.

create  partition  primary
format  fs=ntfs  label="BOOTCAMP"  quick
assign  letter=w


The command below quits the command diskpart.

exit

12. Copy the Windows files to the Windows partition. First, enter the commands given below to determine name of the file containing the Windows files. I will assume the displayed file name is install.esd.

cd  /d  T:\
dir  /s  /b  install.wim  install.esd


If you get the file install.wim, make the appropriate substitution when entering the commands given below. Next, enter the following command to determine the index of the Windows image you wish to install.

dism  /Get-ImageInfo  /ImageFile:T:\sources\install.esd


For my install.esd file, the index shown for the name Windows 10 Pro was 8. I will use this value in the command shown below. This command will copy the Windows files to the "BOOTCAMP" volume.

dism  /Apply-Image  /ImageFile:T:\sources\install.esd  /index:8  /ApplyDir:W:\  /CheckIntegrity


Note: When entering the above command, the parameter /name:"Windows 10 Pro" could have been substituted for /index:8.

13. Add the Apple supplied drivers to the drivers store. This can be accomplished by entering the command shown below.

dism  /Image:W:\  /Add-Driver  /Driver:T:\$WinPEDriver$  /Recurse  /ForceUnsigned


Note: If any drivers are ineligible, you may see error messages. This is normal, so such error messages can be ignored.

14. Write the boot files to the EFI partition. The command to use is given below.

bcdboot  w:\windows  /s  s:

15. Disable the ability to boot from the "WINSTALL" volume. This can be accomplished by entering the command shown below. This will rename the folder containing the boot files.

rename  t:\efi  noefi

16. Enter the command shown below to quit the Command Prompt Window.

exit


This should result in an image similar to what is displayed below. Select "Turn off your PC", then wait for the Mac to completely shut down.

17. You need to finish the initialization of Windows 10. Hold down the option key immediately after turning on your Mac. Release the option when the Startup Manager window appears. Select the icon labeled "EFI boot". Next, hold down the control key while choosing the circular arrow below the "EFI boot" label.

18. Proceed until you reach the screen where you are prompted for your region. For the 1709 version (OS build 16299.15) of Windows 10, your the screen will appear as shown below.

For other versions of Windows 10, the screen could appear different. As an example, the screen, for the 1507 version (OS build 10240) of Windows 10, would appear as shown below.

Note: At this point, prohibiting your Mac access to the internet is generally a good idea. For example, unplug any ethernet cables or disable Wi-Fi access that does not require encryption.

Next, press the control+shift+F3 keys to restart Windows 10 in Audit mode.

19. When desktop shown below appears, use the Windows File Explorer to open the Windows Support Software application named "Setup". This application can be found in the "BootCamp" folder on the "WINSTALL" drive. After the installer application completes, allow the computer to restart.

20. Next, boot to the Windows Recovery Environment. Basically, hold down the shift key while selecting to restart Windows.

21. Navigate to a Windows Command Prompt by following the instructions given below.

In the image shown below, select "Troubleshoot".

In the image shown below, select "Advanced options"

In the image shown below, select "Command Prompt".

After a short delay, you should get an image similar to what is shown below. Choose the Administrator account to continue.

Next, you should get an image similar to what is shown below. Select "Continue".

The result should be the image shown below.

22. Delete the "WINSTALL" partition and extend the "BOOTCAMP" volume to reclaim the free space. The procedure is given below.

Enter the following pair of commands to start diskpart and list the current volumes.

diskpart
list  volume


From the output of the command list volume, determine the number for the volume with the label "WINSTALL". In this example, I will assume this number is 1. Your number could be different. Also, determine the number for the volume with the label "BOOTCAMP". In this example, I will assume this number is 0. Again, your number could be different.

The next pair of commands selects the "WINSTALL" volume and then deletes the corresponding partition.

select  volume  1
delete  partition


The next pair of commands selects the "BOOTCAMP" volume and then extends the corresponding partition to consume the deleted space.

select  volume  0
extend


The next pair of commands quits dispart and closes the window.

exit
exit

23. In the image shown below, select "Continue" to boot back to Windows 10.

24. You will return to the Administrator's desktop displaying the "System Preparation Tool" window. In this window, select "Shutdown" under the "Shutdown options", as shown below.

Note: Your screen may also include a window labeled "Boot Camp", which can be ignored.

Next, select "OK" to shutdown the Mac. At this point, you have completed the installation of Windows 10.

Note: If you prohibited your Mac access to the internet in an earlier step, you may now want to allow access before turning your Mac back on. In other words, plug in the ethernet cable or turn the Wi-Fi back on.

Next time you turn on your Mac, Windows will start in the "Out of the Box Experience" mode. This is basically the way a newly purchased PC starts up, when Windows 10 is already installed.

Note: When asked, be sure to select an Apple keyboard.

If asked, I can clarify any of the above steps

Guys you can forget the complicated command prompts, I found a different way :

1. Install windows in Boot Camp
2. Exit Mac os and Boot in Window
3. Migrate system to an external drive such as Samsung Evo 850 SSD using the free Samsung Migrating Software.
4. Go back to Mac OS and open Boot Camp Assistant.Click continue to remove the created Boot Camp Partition.
5. Exit Mac OS (El Capitan or Sierra).
6. Restart and Hold Option Key.
7. Choose to Boot in EFI Drive.

Voila. Simple.

Simple as this!

Use windows GO, i've tested in my MBPr 2015 in a Samsung 850 Evo and works like a charm.

Followed this method