MS-DOS and Windows command line label command

Updated: 04/02/2019 by Computer Hope
label command

The label command is used to view or change the label of a computer's drives.

Availability

Label is an external command that is available for the following Microsoft operating systems. MS-DOS 4.0x and earlier used label.com as the external file. MS-DOS 5.0 and versions of Windows that support this command use label.exe as the external file.

Label syntax

Windows Vista and later syntax

LABEL [drive:][label]
LABEL [/MP] [volume] [label]

drive: Specifies the drive letter of a drive.
label Specifies the label of the volume.
/MP Specifies that the volume should be treated as a mount point or volume name.
volume Specifies the drive letter (followed by a colon), mount point, or volume name. If volume name is specified, the /MP flag is unnecessary.

Windows XP and earlier syntax

LABEL [drive:][label]

drive: Specifies the drive letter of a drive.
label Specifies the label of the volume.

Label examples

label a: hope

The example above would label the floppy diskette in drive A: to "hope," but will not label if your disk is write-protected.

Possible issues

If your hard drive label contains ASCII or other extended characters and you are running MS-DOS 6.0 or lower, running ScanDisk may corrupt the hard drive.

Because ScanDisk is looking for corrupt or incorrect data, if the hard drive label has ASCII or any unrecognized characters it will attempt to fix those characters. If ScanDisk attempts to fix your label, it may remove all information and place it into a CHK file.

If the hard drive has unrecognizable characters, unable to delete the partition using fdisk.

Use label to recreate the label and then use fdisk to delete the partition after label created.

Questions and answers

Additional information

  • See our label definition for further information and related links on this term.