Get the fix to boot-related error “NTDETECT failed” and other NTDETECT.COM problems affecting Windows XP.

About “ntdetect failed”

The following information on this error has been compiled by NeoSmart Technologies, based on the information gathered and report by our global network of  engineers, developers, and technicians or sister organizations.

Description and Symptoms

The error messages, alerts, warnings, and symptoms below are tied to this error.

Symptom 1: ntdetect failed

NTDETECT, a critical component of the Windows XP boot process, is required for the correct operation of NTLDR, the Windows XP bootloader.

If NTDETECT is found, but unable to execute properly for a variety of possible reasons, a message stating “ntdetect failed” may be displayed. This is often encountered when attempting to boot into the Windows XP CD.

Setup is inspecting your computer's hardware configuration...  NTDETECT failed

Setup is inspecting your computer's hardware configuration...


Causes of this Error

This error has been known to occur as a result of one or more of the following:

Cause 1: Incompatible NTDETECT version

NTDETECT.COM ships with Windows and is typically installed from the Windows setup CD.

Older versions of NTDETECT have problems reading NTFS filesystems from newer drives and identifying/communicating with newer hardware. If NTDETECT.COM is downgraded to an older version for some reason (incomplete or interrupted Windows installation or setup attempt, incorrect Windows Update hotfix installed, etc.), this error may present.

Cause 2: Corrupted NTDETECT file

NTDETECT, located in the root of the boot partition on disk 0, can become corrupted as a result of a virus infection, sudden loss of power during writes to the boot partition, or a failed Windows Update.

Cause 3: Compressed NTDETECT.COM file

NeoSmart’s computer troubleshooting engineers have identified that one of the most common (yet unidentified) cases of “NTDETECT failed” errors is as the result of incorrect or improper compression of the boot partition.

Key Windows boot files must never be compressed, and many 3rd party products will attempt to compress all files on the system partition — including NTLDR, BOOT.INI, and NTDETECT.COM — resulting in this error. Also attempts at compressing the boot partition with DoubleSpace, DriveSpace, or manually enabling NTFS file compression will cause this error to occur as well.

Cause 4: Fragmentation of NTDETECT.COM

On NTFS or FAT partitions with a small enough cluster size, NTDETECT.COM may be written to non-adjacent clusters through an occurrence known as file fragmentation.

t is unknown whether any of the NTLDR versions that Microsoft has shipped over the years are capable of reading an NTDETECT.COM file spread over multiple non-consecutive clusters on-disk, and NTDETECT should be defragmented to be stored on consecutive blocks on the filesystem to resolve this scenario.

Guaranteed Fix: Use Easy Recovery Essentials

Easy Recovery Essentials is guaranteed to fix the “NTDETECT failed” error automatically using its built-in Automated Repair option. EasyRE is currently available for Windows XP, Vista, 7 and 8 and can be downloaded and created on any PC.

  1. Download Easy Recovery Essentials. Make sure to note your Windows version (XP, Vista, 7 or 8) before you download EasyRE. This guide can help you identify what version of Windows you have installed.
  2. Burn the image. Follow these instructions on how to burn the bootable ISO image very carefully, as making a bootable CD can be tricky! Alternatively, these instructions explain how to create a bootable EasyRE recovery USB stick/drive.
  3. Boot up your PC from the Easy Recovery Essentials CD or USB you created.
  4. Once EasyRE is running, choose the “Automated Repair” option and click Continue.
    EasyRE Home

    Choose “Automated Repair” in Easy Recovery Essentials

  5. After EasyRE scans your computer’s drives, identify and select the drive letter for your Windows installation from the list, and then click on the Automated Repair button to begin.
    EasyRE displays a list of found Windows operating systems

    Choose the drive associated with the Windows installation you’re trying to repair.

  6. Easy Recovery Essentials will start analyzing the selected drive for problems. EasyRE will test for and attempt to automatically correct errors with the disk, partition, bootsector, filesystem, bootloader, and registry. No intervention is required, as EasyRE’s repair is fully automated:
    EasyRE: Automated Repair

    Easy Recovery Essentials searches for errors and makes corrections to the selected Windows installation.

  7. Once the process is complete, EasyRE will report its findings. Click on the Restart button to reboot your PC and test the changes.
  8. The “NTDETECT failed” error should now be fixed as your PC begins to load:
    EasyRE: Automated Repair

    Windows, booting up successfully.

You can download Easy Recovery Essentials from here.

Other fixes for NTDETECT failed in Windows XP

Windows Setup CD/DVD Required!
Some of the solutions below require the use of the Microsoft Windows setup CD or DVD. If your PC did not come with a Windows installation disc or if you no longer have your Windows setup media, you can use Easy Recovery Essentials for Windows instead. EasyRE will automatically find and fix many problems, and can also be used to solve this problem with the directions below.

Fix #1: Restore NTDETECT.COM

If the NTDETECT file itself has become corrupted or damaged as a result of one or more of the scenarios explained above, or if an older/incompatible version of NTDETECT has been installed to the system partition, the following instructions will revert it to the correct, compatible version.

It is imperative that the correct Windows setup CD (i.e. with the correct service pack and correct 32- or 64-bit architecture) is used for the procedure!

If is in fact missing or corrupt, you can restore the original file back from your Windows XP installation disc.

Unable to boot into the Windows setup CD?
See our guide on setting up a PC to boot from the CD or DVD for troubleshooting and more detailed instructions.

  1. Insert your XP CD into the computer.
  2. Restart your computer.
  3. Press any key to boot into the CD when you see the “Press any key to boot from CD” message.
  4. Press R to start Recovery Console when the Options screen appears.
  5. Type in your Administrator password followed by the Enter key to submit it.
  6. You’ll reach the Command Prompt now, type the following command, where D:\ is your CD’s drive letter and C:\ is the letter of the drive you installed Windows to:
    copy D:\i386\ C:\
  7. Press Y when you are asked if you want to overwrite this file and then hit Enter to submit the command.
  8. Restart your computer.

Fix #2: Defragment NTDETECT

If the NTDETECT failed error message is caused by file fragmentation, it can be resolved by attempting to defragment either the individual NTDETECT.COM file or the filesystem it is on. You can defragment NTDETECT.COM by using the free contig utility from Microsoft (originally developed by Sysinternals):

  1. Download from Microsoft at this link
  2. Extract contig.exe from
  3. Launch a command process window (Start | Run | cmd.exe) and use CD to navigate to the directory you extracted contig.exe
  4. Finally, run contig.exe against the NTDETECT.COM file you need to defrag:
    cd Downloads
    contig.exe D:\
  5. Wait for it to finish.

    contig result

Fix #3: Using chkdsk to repair filesystem errors

If this problem is being caused by a corrupt boot or system partition, it may be repaired by scanning the NTFS or FAT32 partition for errors or corruption. chkdsk will verify files and data on the disk.

Here are the steps:

  1. Insert your Windows CD; restart your computer.
  2. Boot into the CD by pressing any key when the “Press any key to boot from CD” message appears on your computer.
  3. Press R to open the Recovery Console once at the Options menu.
  4. Type in your Administrator password; hit Enter
  5. At the command prompt, type in the following command and press Enter
    chkdsk /r
  6. After the chkdsk process is completed, restart your computer. Make note of any warnings or alerts that chkdsk prints.

More Information

Linked Entries

The errors below have been verified as being associated with or related to this problem:

Support Links

Applicable Systems

This Windows-related knowledgebase article applies to the following operating systems:

  • Windows XP (all editions)
  • Windows Server 2003 (all editions)