Facebook Picture Secrets Revealed: An Analysis of Facebook’s Photo Compression


Facebook.  For many, it is the bane of their existence.  For many businesses, especially photographers like me, a necessary evil.  For years, photographs posted on Facebook lost much of their lustre and clarity, undergoing some brutal unknown compression to shrink the file size to a manageable size for storage and web loading.   This is completely understandable given the number of active Facebook users and the millions of images they upload.  For we photographers however, it was frustrating, to say the least, to lose so much control over how our images were presented to potential clients through the powerful marketing tool that Facebook is.

As everyone knows, Facebook has been making many changes to their GUI (graphical user interface) lately, including the love-to-hate and hate-to-love Timeline.  But, they’ve also greatly improved their photo presentation.  While a heavy compression is still there, the algorithm is better, and the size presented to your viewers is MUCH larger.

Yet, many people I speak to still don’t fully understand what is happening behind the scenes when posting their hard work to Facebook, and wonder why it’s fuzzy.  Well, this post is here to help you understand a little bit of what’s happening, and help guide you in formatting your pictures to look their best on Facebook by fully analyzing different images and what happens once they reach Facebook so you can predict and better control the presentation.  No, you can’t circumvent Facebook’s compression, but by embracing it and understanding it, you’ll have more control over your own images.

If you are a quick and dirty kind of person, like me, and just want an answer to the question “What size should I make my images look their best on Facebook??  Help me!”, here it is.  My research has found this to be the best image on Facebook and the least affected by Facebook’s compression algorithm and looks great on mobile devices as well as various monitor sizes.

  • 72dpi
  • 1200px long edge (Landscape) or 900px long edge (portrait)
  • JPEG with sRGB colorspace (although, Facebook will replace ANY colorspace you submit with sRGB… just don’t submit with NO embedded colorspace)
  • Photoshop level 8.  (Or, approximately 75-80 out of 100 in other applications like Lightroom)

Quick sidebar… while it’s common practice to REMOVE your embedded color space profile (usually sRGB for web) when posting to the web, it is NOT advisable when posting to Facebook.  FB is expecting SOME color embedding and even though it will change ANY embedded profile to sRGB, it chokes and makes images look like crap without SOMETHING there.

Now, if you want more details about WHY I upload new images in this size, read on….

First, when we upload, we need to accept that Facebook is going to ‘shrink’, or compress our image to some extent, no matter WHAT size it is.  What we want to accomplish is upload a photo formatted and sized in such a way to limit how MUCH it does that, so that what we upload is as close to what we see in Photoshop or on our own computer as possible.

Let’s take a look at my first two experiments with uploading below.

I started with a basic square photo at 3900px, and 300ppi saved as a JPEG using Photoshop at a level of 12.  You’ll see it was a pretty good size at 17MB, but this was a nearly lossless image when first saved.  After uploading however, Facebook modified the file down to a resolution of 72ppi (standard for monitors and the web), but also changed the edge resolution down to 2048px.    In the red boxes, you’ll see that we lost 76% of our ppi, almost 50% of our resolution, and a whopping 91% of our overall file size!  This is data loss folks… by uploading the image like this, we’re allowing Facebook to cookie cutter compress our images like every other image users upload.  The ‘Presentation’ size at right is a percentage of the resultant 2048 image in my browser window on a 1920 x 1200 monitor which is noted as the ‘Scaled to’ value.

Let’s talk about that ‘Presentation’ size for just a moment.  Facebook image windows will resize your image – via the browser and the underlying HTML/PHP code – to fit the browser and screen of the viewer.  Most monitors now days are pretty high in resolution, with the old 1024 x 768 monitors pretty rare.  But, they are out there, and so are mobile devices like iPads and smart phones with smaller screens, so a dynamic resize is essential.  This resize though is non destructive (for the most part) to your image quality.  Meaning, your original image (post FB compression) is un-modified.  To see how this works, open an image on Facebook and then resize your browser window by dragging the corners of the window.  The image will grow and shrink to the size of your window.   I note size changes in more analysis, but overall, we aren’t going to concern ourselves TOO much with this figure.  So, depending on your monitor viewing size, and the browser window size ON that monitor, the ‘scaled to’ value will change.  For these tests, I was again on a 1920 x 1200 monitor in Firefox maximized on Windows 7.

Back on track… so, my fullsize image lost quite a bit of data via Facebook’s compression algorithm.  Since, through this, I discovered that Facebook’s maximum stored size is 2048px, I decided to redo this test but with a resize to 2048.

So, I uploaded two more images, both at 2048px on the edge, at 300ppi, with one saved at PS12, and the other at PS8.  First thing you’ll notice is my resolution didn’t change from what I uploaded to what Facebook presented me when viewing it live and online.  I had 0% loss in overall stored resolution.  My ppi still dropped 76% because well, no point in storing a 300ppi photo when the web can’t support it.  More importantly though, notice the difference in filesize between the ‘lossless’ JPEG save (PS12) and the PS8 saves.  The PS12 file lost 73% of its file size.  So, what did Facebook strip out?  We don’t know… however, the PS8 file only lost 16% of its file size.  MUCH better, and I consider that acceptable.  Our presentation size though, even on my 21″ monitor, is still being dynamically shrunk by 51%

So, by now I know that there’s no point in uploading a 300ppi image (I knew that before, but now I’ve proved it) because FB will just change it to 72ppi.  So, why not do that first on MY end, apply any additional edits to keep the image sharp and then upload an image at 72ppi initially.  Let’s try that:

Wow, look at that… the 2048px image at 72ppi and PS12 didn’t lose any pixels per inch or resolution.  However, we still lost 74% of our file size, which again, is data loss.  Now look at the slightly compressed file saved at PS8.  We lost just a hair over 16% of our file size.  Are you seeing a pattern yet?  Both files, because of the still large image at 2048, are being resized down by 52% even on my 21″ monitor.  We’ll work on that next because, even though less impactful than modifying the actual file, the presentation size does affect your image quality.  However, I think we’re getting closer.

So next, I got a little more aggressive.   I tried a few more options.

Obviously, we’ve honed in on the PPI and resolution requirements of Facebook, but obviously, any image (regardless of resolution or size) saved at PS12 is compressed immensely.  My first image, even though at the desired 72ppi, a smaller 1200px edge (yielding only 17% shrink in presentation size), is still losing 75% of its file size.  Saving that same image at PS8 gave me a more reasonable 22% file shrinkage.  Also, if you start to look back up at previous tests, Facebook’s compression has NOTHING to do with file size, but HOW you saved the file.  My largest size was my first one at 1.5MB after upload, but later images (like those in this latest test) were originally LESS than that first image’s post-compression size, but STILL got compressed even more.  This becomes evident with my last test with the image saved at a PS2 level (which looked horrible even on my PC) which STILL got a 22% file compression!   That indicates that no matter what size you upload you WILL get image compression on Facebook.

So, here’s the full testing chart.  I’ve highlighted my personal selection for images I upload to Facebook or provide to clients for Facebook.  You may wonder why I didn’t select a format that got me the 16% loss instead of the 22% loss.  Well, the additional 6% was a trade-off in my mind for a small file stored on the system and presentation size.  Note that while 1200 horizontal and 900 vertical are Facebook’s maximum viewable resolution, any user can download the origina 2048px image if that’s what you upload.  I really don’t want users to download, but I want to maximize the viewing experience, so selecting a format with 6% more data loss, but presented with 35% less presentation loss, AND keeping the file size at a print-UNfriendly size was appealing.

I will also note that when creating a Facebook gallery, you are given the option of “High Quality” versus, ‘not’.  The low quality is certainly low as noted below.  The LQ version lost almost 99% of its original file size!!!  That’s some serious compression.  So, all my photos are uploaded using the ‘High Quality’ check box when creating a gallery.  What I found for wall photos is the system defaults to the High Quality setting.

Hopefully all this work will help you determine how to upload your own precious photographic work to Facebook and accept SOME loss while accommodating it and working within the Facebook image compression parameters.  If you like this post, please share.  If you have comments or questions, please comment.  I’ll try to respond to as many as I can.

Update:  8/7/2012

Some of you made the note that at least on your monitor, PPI is irrelevant, which is absolutely true.   To prove this, save out an image at 800×600 at 10ppi and another 800×600 at 300ppi, and on your screen at least, they’ll look identical.  On screen they are, but in print they would be quite different.  However, despite that, Facebook will ALWAYS convert any image to 72ppi (whether you upload 600ppi or 6ppi, FB will convert it to 72ppi), so that is what we were focusing on.

Also, I’ve talked to some other photogs about what they use, and a few upload 1280px on the landscaped long side for mobile users, but I haven’t seen a difference on my mobile use (iPhone, Android and iPad) between 1280 and 1400.  Just throwing it out there.  I’ve also since bumped my output to 95 in Lightroom.   I also set screen sharpening to MAX.  Thus far, I’ve been quite happy with the output.  While my other data was accurate, many of the images still seemed a bit soft, and the additional ‘over’ sharpening seems to work better with FB’s compression.  Thanks to a fellow photog for that tip.

Below is a screen-shot of relevant settings for my LR preset (click to enlarge):