I'm currently working on optimizing my site to try to decrease load time by using Pingdom tools. I seem to be having some difficulty with long load times on images.

For example, the body background for my site is a 29kb file but takes almost 500 ms to load, the majority of which is spent connecting to the server. This one seems to take the longest times but other images seem to take a lot of time as well—the majority of which seems to be spent connecting to the server.

This also seems to fluctuate as I've seen the same image load in 500ms one minute and ten minutes later load in 1.5 seconds.

My site is using the Modx CMS but I'm not sure if that would affect this at all. Is it more likely that this is a server issue? Is there anything that I should check or do to help alleviate these inflated 'connect' times?

enter image description here

  • 2
    Do you have a lot of redirects in your access log, or are images pulled raw from a database as base64 or something? Consider also using a content delivery network (CDN) to host your static content (images).
    – ionFish
    May 7, 2012 at 18:52
  • The images are currently not stored in a database. I have considered a CDN in the past but haven't looked into it too far. Do you recommend one for an organization with a relatively tight budget?
    – Vecta
    May 7, 2012 at 19:06
  • Small budget? Definitely recommend Amazon AWS, at aws.amazon.com You can scale your resources, from small to massive, and you are only billed for the resources you actually use. (Not a monthly flat fee).
    – ionFish
    May 7, 2012 at 19:13
  • @ionFish, comments like your first comment should be an answer instead of a comment. That way it doesn't confuse people what stumble upon this question from Google and Vecta can mark it as the correct answer. May 8, 2012 at 4:22

2 Answers 2


Since the majority of time is spent connecting to the server (also known as Time To First Byte), there is likely a problem on the server somewhere.

If the images are served through some server-side code (e.g. PHP) then obviously check your script for optimisations you can implement. If you are simply serving files direct then it could be a problem with .htaccess files - maybe you have too many rules that the server is trying to process in each request.

Another solution is to use a Content Delivery Network such as Amazon AWS. They serve the images from as close to the visitor as possible.


Simple answer, sign up to cloudflare.com. It's a free CDN that will also do things like optimize your site. We use them on a few sites and they do a good job.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.