How can I add my license key to my USB windows 7 install?

12,056

DISM Image Management Command-Line Options

DISM Windows Edition-Servicing Command-Line Options

Set the Windows key with DISM, you will be creating a new install.wim which exists in your current windows install cd/dvd/usb iso.

  1. Extract the install.wim from your windows iso
  2. Create a folder and mount the install.wim
  3. Open command prompt (as admin) and and mount the install.wim

NOTE: "/INDEX:1" might be different on your WIM depending on how many Window editions that are available on your cd/dvd. Keys will be different for each Windows edition.

DISM /MOUNT-WIM /WIMFILE:c:\INSTALL.WIM /INDEX:1 /MOUNTDIR:c:\temp

  • Set the Windows product key

DISM /IMAGE:c:\temp /Set-ProductKey:Bxxx-Pxxx-Pxxx-Qxxxx-FxxxR

  • Commit the changes to the install.wim

DISM /UNMOUNT-WIM /MOUNTDIR:c:\temp /COMMIT

  • Replace the install.wim in the .iso with the one you just created.
Share:
12,056

Related videos on Youtube

corsiKa
Author by

corsiKa

I'm here to find out about the mysteries of air.

Updated on September 18, 2022

Comments

  • corsiKa
    corsiKa almost 2 years

    I'm making my USB bootable Windows 7 install, and I'd like to put my license key on the install media. I've looked online but can't seem to find anything on this, and on my own I don't even know where to begin.

    How can I make my install automatically input my license key during the install?

    • corsiKa
      corsiKa almost 10 years
      I noticed there's a close vote for "unclear what you're asking" - i'm not sure where this comes from, but if there's anything unclear about this question please let me know. I want to make my windows 7 install on my usb drive automatically input my license key.
    • Canadian Luke
      Canadian Luke almost 10 years
      there is only one vote to close, so I wouldn't worry much about it at this point. It's clear what you are asking, but the title could use improvement
  • corsiKa
    corsiKa almost 10 years
    So it's nothing to do with the media (usb/dvd) but rather editing the ISO itself?
  • corsiKa
    corsiKa almost 10 years
    Well I know at work we use a fancy program with preinstalled apps and all that jazz, and then they have software delivery tools on top of that. But this is just for at home and I don't want to spend thousands of dollars on such tools. I'll try this out and see how it goes. Thanks!
  • Logman
    Logman almost 10 years
    do you expect to install windows 7 a lot? it usually isn't worth the trouble for home user.
  • corsiKa
    corsiKa almost 10 years
    I don't expect to install it a lot, but I will be doing my install on stream and do not want to enter it on the stream (for obvious reasons). I'm not sure what the camera angles will be so it will probably be hidden anyway, but just the time to enter that being saved will be nice. I'm willing to invest the time now to make that time less.
  • Logman
    Logman almost 10 years
    NLite does not support Vista/Win7/Win8... only XP/2003. Which is when they switched to the wim format.
  • jiggunjer
    jiggunjer over 8 years
    The newer NTLite does, as does RT Seven Lite and WinToolkit.