Definition of:compacting files
compacting files

Removing unused space in a stored file. Saving a copy of a file may compact the file by default if the original file was updated several times. Updating tends to fragment a file, which can cause space to be wasted, but saving the file as a copy stores the data sequentially from the start.

Compacting Mailboxes
An e-mail mailbox is a file that contains multiple messages. Deleting messages within the file often works like deleting files on the disk. The data are still intact, but the index to the data is marked as deleted. Compacting a mailbox eliminates the wasted space, which may be done automatically by the e-mail program or by the user selecting a Compacting option from a menu. In e-mail jargon, a mailbox may be called a "folder," but it is very often just a type of file.