# Del (command)

> Mediated Wiki article. Canonical URL: https://mediated.wiki/source/Del_(command)
> Markdown URL: https://mediated.wiki/source/Del_(command).md
> Source: https://en.wikipedia.org/wiki/Del_(command)
> Source revision: 1347872958
> License: Creative Commons Attribution-ShareAlike 4.0 International (https://creativecommons.org/licenses/by-sa/4.0/)

{{Short description|Command in various operating systems}}
{{lowercase}}
{{Infobox software
| name                   = del / erase
| logo                   = 
| screenshot             = ReactOS-0.4.13 del command 667x530.png
| screenshot size        = 
| caption                = The [ReactOS](/source/ReactOS) <code>del</code> command
| developer              = [DEC](/source/Digital_Equipment_Corporation), [Microware](/source/Microware), [Microsoft](/source/Microsoft), [IBM](/source/IBM), [DR](/source/Digital_Research),  [Datalight](/source/Datalight), [Novell](/source/Novell), [JP Software](/source/JP_Software), ReactOS Contributors
| released               = 
| latest release version = 
| latest release date    = 
| operating system       = [RT-11](/source/RT-11), [OS/8](/source/OS%2F8), [RSX-11](/source/RSX-11), [OpenVMS](/source/OpenVMS), [DOS](/source/DOS), [OS-9](/source/OS-9), [MSX-DOS](/source/MSX-DOS), [FlexOS](/source/FlexOS), [SISNE plus](/source/SISNE_plus), [OS/2](/source/OS%2F2), [Windows](/source/Microsoft_Windows), [ReactOS](/source/ReactOS), [KolibriOS](/source/KolibriOS), [SymbOS](/source/SymbOS), DexOS
| platform               = [Cross-platform](/source/Cross-platform)
| genre                  = [Command](/source/Command_(computing))
| license                = 
| website                = 
}}
In [computing](/source/computing), '''<code>del</code>''' (or '''<code>erase</code>''') is a [command](/source/command_(computing)) in [command-line interpreter](/source/command-line_interpreter)s ([shells](/source/Shell_(computing))) such as <code>[COMMAND.COM](/source/COMMAND.COM)</code>, <code>[cmd.exe](/source/cmd.exe)</code>, [4DOS](/source/4DOS), [NDOS](/source/NDOS), [4OS2](/source/4OS2), [4NT](/source/4NT_(shell)) and [Windows PowerShell](/source/Windows_PowerShell). It is used to delete one or more [files](/source/computer_file) or [directories](/source/directory_(file_systems)) from a [file system](/source/file_system).

==Implementations==
The command is available for various [operating system](/source/operating_system)s including [DOS](/source/DOS), [Microware](/source/Microware) [OS-9](/source/OS-9),<ref>{{cite book|author=Paul S. Dayan|year=1992|title=The OS-9 Guru - 1 : The Facts|publisher=Galactic Industrial Limited|isbn=0-9519228-0-7}}</ref> [IBM](/source/IBM) [OS/2](/source/OS%2F2),<ref>{{Cite web |url=http://www.jatomes.com/Help/Os2Cmd.php#ERASE |title=JaTomes Help - OS/2 Commands |access-date=2019-07-20 |archive-date=2019-04-14 |archive-url=https://web.archive.org/web/20190414130029/http://www.jatomes.com/Help/Os2Cmd.php#ERASE |url-status=dead }}</ref> [Microsoft](/source/Microsoft) [Windows](/source/Microsoft_Windows)<ref>{{Cite web|url=https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2012-r2-and-2012/cc771049(v=ws.11)|title=Del|website=docs.microsoft.com|date=31 August 2016 }}</ref> and [ReactOS](/source/ReactOS).<ref>{{Cite web|url=https://github.com/reactos/reactos|title=reactos/reactos|website=GitHub|date=3 January 2022}}</ref> It is analogous to the [Unix](/source/Unix) <code>[rm](/source/rm_(Unix))</code> command and to the [Stratus](/source/Stratus_Technologies) [OpenVOS](/source/Stratus_VOS) <code>delete_file</code> and <code>delete_dir</code>commands.<ref>{{cite web |url=http://stratadoc.stratus.com/vos/19.1.0/r098-19/wwhelp/wwhimpl/common/html/r098-19.pdf |title=Reference manual|website=stratadoc.stratus.com |access-date=2020-09-14}}</ref>

[DEC](/source/Digital_Equipment_Corporation) [RT-11](/source/RT-11),<ref>{{Cite web|url=http://paleoferrosaurus.com/beta/documents/rt11help.html#DELETE|title=RT-11 HELP FILE|website=paleoferrosaurus.com|access-date=2019-07-06|archive-date=2018-07-17|archive-url=https://web.archive.org/web/20180717041552/http://paleoferrosaurus.com/beta/documents/rt11help.html#DELETE|url-status=dead}}</ref> [OS/8](/source/OS%2F8),<ref name="OS8.HandB">"Concise Command Language" (CCL).{{cite web
|url=http://bitsavers.trailing-edge.com/pdf/dec/pdp8/os8/OS8_Handbook_Apr1974.pdf
|title=OS/8 Handbook |date=April 1974 |access-date=28 November 2017}}</ref> [RSX-11](/source/RSX-11),<ref>{{Cite book |title=RSX A Guide for Users |date=1987 |author=John F. Pieper |publisher=Digital Equipment Corporation |url=http://www.rsx11m.com/rsxguide.pdf |isbn=0-932376-90-8 |access-date=2020-09-19}}</ref> and [OpenVMS](/source/OpenVMS)<ref>{{Cite web|url=https://www.itec.suny.edu/scsys/vms/OVMSDOC073/v73/6489/6489pro_005.html|title=OpenVMS User's Manual|website=www.itec.suny.edu}}{{Dead link|date=October 2023 |bot=InternetArchiveBot |fix-attempted=yes }}</ref> also provide the <code>delete</code> command which can be contracted to <code>del</code>. [AmigaDOS](/source/AmigaDOS)<ref>{{Cite book|url=https://archive.org/details/1988-rugheimer-spanik-amigados-quick-reference|title=AmigaDOS quick reference|first1=Hannes|last1=Rügheimer|first2=Christian|last2=Spanik|date=September 14, 1988|publisher=Grand Rapids, Mi : Abacus|isbn=9781557550491|via=Internet Archive}}</ref> and [TSC](/source/Technical_Systems_Consultants) [FLEX](/source/FLEX_(operating_system))<ref>{{Cite web|url=http://www.flexusergroup.com/flexusergroup/pdfs/flex2um.pdf|title=FLEX 2.0 User's Manual}}</ref> provide a <code>delete</code> command as well.

The <code>erase</code> command is supported by [Tim Paterson](/source/Tim_Paterson)'s [SCP](/source/Seattle_Computer_Products) [86-DOS](/source/86-DOS).<ref>{{cite book |title=86-DOS - Disk Operating System for the 8086 - User's Manual |edition=Preliminary |version=Version 0.3 |date=1980 |publisher=[Seattle Computer Products, Inc.](/source/Seattle_Computer_Products%2C_Inc.) |location=Seattle, Washington, USA |url=http://www.patersontech.com/Dos/docs/86_Dos_usr_03.pdf |access-date=2019-07-14 |url-status=dead |archive-url=https://web.archive.org/web/20190714004434/http://www.patersontech.com/dos/docs/86_Dos_usr_03.pdf |archive-date=2019-07-14}} (59 pages)</ref> On [MS-DOS](/source/MS-DOS), the command is available in versions 1 and later.<ref name="RUNNINGMSDOS">{{Cite book|author-last=Wolverton|author-first=Van|title=Running MS-DOS Version 6.22 (20th Anniversary Edition), 6th Revised edition|date=2003|publisher=[Microsoft Press](/source/Microsoft_Press)|isbn=0-7356-1812-7}}</ref> It is also available in the [open-source](/source/open-source_software) MS-DOS [emulator](/source/emulator) [DOSBox](/source/DOSBox).

[Datalight](/source/Datalight) [ROM-DOS](/source/ROM-DOS) also includes an implementation of the {{code|del}} and {{code|erase}} commands.<ref>{{Cite web|url=https://www.datalight.com/assets/files/ROM-DOS_Users_Guide.pdf|title=Datalight ROM-DOS User's Guide|website=www.datalight.com}}</ref>

While [Digital Research](/source/Digital_Research) [DR-DOS](/source/DR-DOS) supports <code>del</code> and <code>erase</code> as well, it also supports the shorthand form <code>era</code>, which derived from [CP/M](/source/CP%2FM). In addition to this, the DR-DOS command processor also supports <code>delq</code>/<code>eraq</code>. These are shorthand forms for the <code>del</code>/<code>era</code>/<code>erase</code> command with an assumed <code>/Q</code> parameter (for 'Query') given as well.<ref name="drdos6userguide">[https://www.4corn.co.uk/archive/docs/DR%20DOS%206.0%20User%20Guide-opt.pdf DR DOS 6.0 User Guide Optimisation and Configuration Tips]</ref>

[THEOS/OASIS](/source/THEOS)<ref>[http://www.bitsavers.org/pdf/phaseOneSystems/THEOS_OASIS_Users_Handbook_1985.pdf THEOS/OASIS User′s Handbook]</ref> and [FlexOS](/source/FlexOS)<ref>{{cite web |url=http://www.bitsavers.org/pdf/digitalResearch/flexos/1073-2003_FlexOS_Users_Guide_V1.3_Nov86.pdf |title=FlexOS User's Guide |date=1986 |website=www.bitsavers.org |access-date=2020-09-14 |archive-date=2019-09-25 |archive-url=https://web.archive.org/web/20190925131719/http://bitsavers.org/pdf/digitalResearch/flexos/1073-2003_FlexOS_Users_Guide_V1.3_Nov86.pdf |url-status=dead }}</ref> provide only the <code>erase</code> command.

In [PowerShell](/source/PowerShell), <code>del</code> and <code>erase</code> are predefined [command aliases](/source/Alias_(command)) for the <code>Remove-Item</code> [cmdlet](/source/cmdlet) which serves the same purpose.

==Syntax==
<syntaxhighlight lang="doscon">
>del filename
>erase filename
</syntaxhighlight>

==See also==
*[deltree](/source/deltree)
*[rmdir](/source/rmdir)
*[List of DOS commands](/source/List_of_DOS_commands)
*[List of Unix commands](/source/List_of_Unix_commands)

==References==
{{Reflist}}

==Further reading==
*{{Cite book|author-last=Wolverton|author-first=Van|title=MS-DOS Commands: Microsoft Quick Reference, 4th Revised edition|date=1990|publisher=[Microsoft Press](/source/Microsoft_Press)|isbn=978-1556152894}}
*{{Cite book|author1=Kathy Ivens|author2=Brian Proffit|year=1993|title=OS/2 Inside & Out|publisher=[Osborne McGraw-Hill](/source/Osborne_McGraw-Hill)|isbn=978-0078818714}}
*{{Cite book|first=Æleen|last=Frisch|year=2001|title=Windows 2000 Commands Pocket Reference|publisher=[O'Reilly](/source/O'Reilly_Media)|isbn=978-0-596-00148-3}}

==External links==
{{Wikibooks|Guide to Windows Commands}}
*[https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/del del | Microsoft Docs]

{{Windows commands}}

Category:Internal DOS commands
Category:MSX-DOS commands
Category:OS/2 commands
Category:ReactOS commands
Category:Windows commands
Category:Microcomputer software
Category:Windows administration
Category:File deletion

---
Adapted from the Wikipedia article [Del (command)](https://en.wikipedia.org/wiki/Del_(command)) by Wikipedia contributors ([contributor history](https://en.wikipedia.org/wiki/Del_(command)?action=history)). Available under [Creative Commons Attribution-ShareAlike 4.0 International](https://creativecommons.org/licenses/by-sa/4.0/). Changes may have been made.
