What is file compression?

By Mark Boreland ·

In short

  • File compression shrinks a file by encoding it more efficiently, so it transfers faster and uses less storage.
  • Some compression is lossless, like a ZIP, and some is lossy, like a JPEG, which trades a little quality for a lot of size.
  • Smaller files upload faster, load faster for the recipient, and fit under size limits.

Compression rewrites a file so the same content takes fewer bytes. Lossless methods, like a ZIP archive or the gzip a server applies on the fly, pack the data so it can be restored exactly. Lossy methods, like JPEG for photos or H.264 for video, throw away detail the eye barely notices in exchange for a dramatic size cut. The right kind depends on the file. Text and code must stay lossless, while a photo can usually lose a little and look identical.

For sharing, smaller is almost always better. A bundle of files you share a ZIP file uploads as one compact archive and serves as a small site. A screenshot that is needlessly large shrinks hard when you convert PNG to WebP, often to a fraction of the original with no visible change, which means the page loads faster for everyone who opens it. The free plan covers files up to 25MB, so compressing first is sometimes the difference between fitting and not.

Servers add another layer for free. Text-based files are typically gzip-compressed in transit, so an HTML page or a JSON file arrives smaller than it sits on disk without you doing anything. Where you have a say is the source file. Pick an efficient format, and the upload and every download afterwards is quicker. Hosting is free to start, and a paid plan raises the ceiling when your files are genuinely large.

Related terms

Frequently asked questions

Related tools

Other things you can do on NudgeHost.

Put it into practice.

Drop a file and get a shareable link in seconds. Free, no card needed.

Share a file now