Minimize Sketch files to a MINIMUM! with 6 simple steps and awesome tools

Second story of mine and again dealing with Sketch … So there is the new Sketch format since the release of 43.1 and now it is as if the Sketch file is a .ZIP file and it actually behaves like a .ZIP file. With some time spent and some tests I discovered the following workflow which will really MINIMIZE file size and help designers in their daily problems, especially files with many images are of interest here … so just give it a try (make sure you did a copy of your file before you start)

1. Better Zip = your friend!

Download BetterZip from https://macitbetter.com and just open the Sketch file with it. BetterZip will show you the Sketch File’s folder structure and directly show you the size of each image. Simply drag the biggest images out of BetterZip into some folder on your desktop. Don’t close BetterZip — you will need it at the end to save the Sketch file after optimizing.

2. Fixing damaged PNG files

At least in my case I had a couple of damaged files. You will see those directly in Finder — they have no thumbnail. Detect those files. Usually they are the biggest in file size AND those files are not used in Sketch at all
Now FIXING the DAMAGED … create a tiny png file (just white rectangle or even transparent) and name those just like the damaged files AND simply delete the damaged files … IT IS IMPORTANT that the naming is exactly as it was before

3. Resize huge images

Another awesome weapon is the th-MakerX http://www5.wind.ne.jp/miko/mac_soft/th-maker_x/index-en.html simply by dragging files on it (from you folder on your desktop) you can resize files to e.g. max width of 2000 px (imho that size is more than enough for most cases of visual design) … of course you can decide per image which size is needed. NOTE: Usage of a high res image for just a thumbnail in a UI makes no sense ; — )

4. Optimizing PNG files with Pngyu

Next awesome tool for you which will remove some meta data from the PNG files and make the files a lot smaller again … http://nukesaq88.github.io/Pngyu/
- as you see here: in some cases it reduces over 80% ! and that WITHOUT visible quality loss

5. Back to BetterZip — Replace images

Simply drag and drop back to BetterZip
… and replace all files … now it’s important that you had a backup copy of the file (normally it works fine but who knows … )

6. Save .SKETCH with BetterZip and be happy ; — )

→ CMD+S
now compare the before and after … you will recognize IT’S A LITTLE LESS NOW ))) open the Sketch File and look for Errors and bugs … I didn’t have any until now …

Have fun and go buy you a coffee ; — )

#illustreet