If you follow me on Twitter, you’ve probably heard that one of the posts from the Wine Club Group that we wrote last year recently “went viral.” Tricia wrote all about what we learned and got out of this event, but I’m going to talk about how we survived (and didn’t even know it was happening).

Last year on National Girl Scout cookie day, we wrote a blog post on pairing wine with Girl Scout cookies. It was, what we call, a “filler piece” and actually created the graphic specifically to be shared on Pinterest. But this year, on Saturday, January 11th at 8:04 PT someone from Lincoln, California found this image in Google Images and then shared it on Facebook. Then, that “viral” thing happened and as of right now, 130,000 other people have liked this post. Plus we’ve had 300 Tweets and over 5,000 pins.

Why didn’t we know it was happening? Because we were at Affiliate Summit! How did the website handle this traffic? We planned ahead.

TinyPNG.com

Before images are uploaded to WordPress, we run them through TinyPNG.com. This image, when I originally saved it, was 350.4 KB in size. After optimizing it, it’s now 90 KB, a 74% reduction in size.

Social Sharing

The image we used on the Wine Club site was actually a JPG, yet still optimized for a balance of quality and size. If you were creating websites back in 1998, you probably read, Creating Killer Websites. Back then, we weren’t optimizing images in case a post went viral, nor were we optimizing for SEO purposes. We were optimizing because people were using 14.4 baud modems to get online! These days, people are spoiled and web designers are lazy.

Amazon Web Services

This site is hosted on my AWS account, with an EC2 web server, RDS MySQL Server, Elasticache Memcache Server, and CloudFront CDN. (Note: if you want to get real hosting set up with AWS, contact Ray). A downside to AWS is that you pay for what you use. Every request, every byte – you pay for it. The upside is that it forces you to do things the right way.

Our image was transferred 130,000 times out of CloudFront, Amazon’s Content Distribution Network (CDN). At 350 KB, that’s 43.4 GB of data. But when we optimize it down to 90 KB, that’s only 11.16 GB. Granted, the cost savings on this one image wasn’t much ($3.87) but these things add up.

Years ago I spoke about on-site SEO – these things still hold true today, and on-site SEO is the only form of SEO which you have complete control over, so do it!

W3 Total Cache

Since our site is powered by WordPress, we needed a WordPress caching plugin. There’s no need for WordPress to generate each page each time it’s requested. We use W3 Total Cache for our caching needs. This includes minifying the code (CSS, JS, HTML), enabling browser cache, caching the page,  and serving static content through a CDN.

Minifying the code takes all unnecessary whitespace and comments out of the files before they’re sent to the browser. Then, these images are served from static.wineclubreviewsandratings.com, which is a CNAME to our CloudFront set-up. CloundFront is a CDN, which means static content (css, js, images) is copied to servers all over the world. When somebody requests a file from the CDN, they’re given the file from the server that’s closest to them, therefore saving time (and taking load off of the web server).

Finally, the post itself is cached and stored in memcache, which is a really fast method of caching (but requires a memcache server – Elasticache in our case).

Social Sharing Widgets

Duh – make it easy for people to share your content! Most WordPress themes have these built-in; I use Sharrre on my own site.

Other Suggestions

Google has a great Page Speed tool which gives you a list of things you can do to make your site faster. Some things take little time, but have a huge impact. And, once you fix them, the change applys to your whole website. Other changes take longer and have little impact, so save those until you’ve taken care of the big problems.

Avoid Over Engineering

Obviously, over engineering comes at a cost, but also serves as a benefit to your users. You could definitely go “too far” and end up spending hundreds (or thousands) of dollars that you don’t need to spend. At the same time, if you do it right the first time, your content can go viral and not end up like this

Hostgator - Going Viral

If you have questions on improving performance of your website and making it faster, ask away in the comments!


3 Comments » for Be Ready For Viral Sharing
  1. Lee says:

    TinyPNG is great. If you want to make it easier there are some decent WordPress plugins that use their API to compress the images when you upload them. It makes it a lot easier to integrate into the work flow. I list a few here: http://wpparadise.com/tinypng-plugins/

    Check them out.

  2. Blaine Wilkerson says:

    Thanks for the great tips! I’m trying to decide on a hosting solution for my upcoming blog(s).
    I went to the AWS site and watched some of the videos, but it all seems a bit “techy” to me. While my knowledge base is growing, and I understand what it does, I need something that is user-friendly so I can focus on my content. Is AWS a good place to start for those who are not fluent in IT? Thanks in advance!

    • Eric Nagel says:

      Hi Blaine,

      Definitely NOT! If you’re not comfortable around a server, go with some standard, $7 / month shared hosting (or hire someone to maintain your server for you)

Leave a Reply

Your email address will not be published. Required fields are marked *

*