ELI5: How can a file become much smaller when zipped, but return to its original size after unzipping?
A file gets smaller when zipped because the zipper finds repeated patterns and squishes them into a shorter way of writing, and it becomes original size again when unzipped because the computer carefully puts all the pieces back in the same order.
Think of it like packing clothes into a suitcase:
- Unzipped is like clothes spread all over the bed.
- Zipped is like folding them neatly and pushing out the extra air.
- Unzipped again is like opening the suitcase and taking the clothes back out.
A zip file does something similar with data:
- It looks for repeated bits or easy-to-shrink parts.
- It stores them in a compact code instead of writing the same thing again and again.
- When you unzip it, the computer uses that code to rebuild the exact same file.
So the file is not really “losing” anything important; it is just being written in a smarter, tighter way. That is why it can shrink for storage and then grow back to the same size afterward.
Ask your own question
Follow-up questions
Test yourself
Three quick questions to see if it stuck. You can challenge a friend after.
Get this entry by email
We'll send it to your inbox, plus one good explanation a week if you like.