How do I run Microsoft Defrag?

Microsoft Windows DefragCaution: Do not run Defrag on a solid-state drive (SSD) or a flash drive. See our defrag an SSD or other flash drivedocument for further information.

Windows XP, 2000, Vista, 7, and 8 users
Windows 95/98 users
Windows NT users
Windows 3.x and MS-DOS users

Windows 2000, XP, Vista, 7, and 8 Defrag

 To run Defrag, we recommend you follow the steps below.

  • Double-click My Computer or open Explorer.
  • Highlight the local hard disk C: drive by clicking on it once.
  • Right-click the highlighted local drive Click Properties
  • Click the Tools tab and click the Defragment now button.

Tip: Windows also supports running Defrag from the Windows command line. For a syntax and full listing of defrag options in the command line see our defrag command page.

Windows 95, 98, and ME Defrag

Windows 95 improved the functionality of Defrag as did Windows 98. To run Defrag from Windows, follow the steps below.

  • Click Start
  • Click Run and type Defrag in the run box
  • Click ok
  • Within the Defrag window, select the drive that you want to be checked and click ok.

Tip: Windows also supports running Defrag from the Windows command line. For a syntax and full listing of defrag options in the command line see our defrag command page.

Windows NT Defrag

Windows NT is not shipped with Microsoft Defrag. However, various third-party companies offer utilities that can Defrag and check your hard drive for you. Symantec a well respected computer company, offers such a program.

Windows 3.x and MS-DOS Defrag

Defrag was first available in MS-DOS 6.0 and was available ever since. If you are running MS-DOS 6.0+ and would like to run Defrag, follow the steps below.

  • If you are in Windows 3.x, click File and then Exit to get to the MS-DOS prompt.
  • From MS-DOS Type CD\DOS and press enter.
  • From the C:\DOS> Type Defrag and press enter, which should begin running Defrag on the computer.

Finally, some computer manufacturers have changed the installation directory of where Defrag is located if you are unable to run Defrag from DOS directory, go to the Windows directory by typing CD\Windows. See the MS-DOS Defrag command page for additional information on this command.

Additional information