Compression is the reduction in size of data in order to save space or transmission time. For data transmission, compression can be performed on just the data content or on the entire transmission unit (including header data) depending on a number of factors.
Content compression can be as simple as removing all extra space characters, inserting a single repeat character to indicate a string of repeated characters, and substituting smaller bit strings for frequently occurring characters. This kind of compression can reduce a text file to 50% of its original size. Compression is performed by a program that uses a formula or algorithm to determine how to compress or decompress data.
Graphic image file formats are usually designed to compress information as much as possible (since these can tend to become very large files). Graphic image compression can be either lossy (some information is permanently lost) or lossless (all information can be restored).
When you send or receive information on the Internet, larger text files, either singly or with others as part of an archive file, may be transmitted in a zip, gzip, or other compressed format. WinZip is a popular Windows program that compresses files when it packages them in an archive.