In computing, the trash (also known as the recycle bin and by other names) is temporary storage for files that have been deleted in a file manager by the user, but not yet permanently erased from the file system. Typically, a recycle bin is presented as a special file directory to the user (whether or not it is actually a single directory depends on the implementation), allowing the user to browse deleted files, undelete those that were deleted by mistake, or delete them permanently (either one by one, or by the "Empty Trash" function).
Within a trash folder, a record is kept of each file and/or directory's original location. On certain operating systems, files must be moved out of the trash before they can be accessed again.
Whether or not files deleted by a program go to the recycle bin depends on its level of integration with a particular desktop environment and its function. Low-level utilities usually bypass this layer entirely and delete files immediately. A program that includes file manager functionality may or may not send files to the recycle bin, or it may allow the user to choose between these options.
A small icon of a waste container for deleting files was implemented during the development of the Apple Lisa user interface in 1982, where it was called the “Wastebasket.” The concept carried over to the Apple Macintosh, as the “Trash”, except in the pre-OS 9 “International English” localization, which retained “Wastebasket.”
Apple Inc. sued to prevent other software companies from offering graphical user interfaces similar to its own. Apple lost most of its claims but courts agreed Apple's Trash icon was original and protected by copyright. Non-Apple software may use other metaphors for file deletion, such as Recycle Bin, Smart Eraser, or Shredder.
In early versions of the Macintosh Finder, Trash contents were listed in volatile memory. Files moved to the Trash would appear there only until the Finder session ended, then they would be automatically erased. When System 7 was released, the Trash became a folder that retained its contents until the user chose to empty the trash.