How to fix Image Swapping Issue in iOS 8 with keep-alive + HTTP Pipe-lining?

We had this problem as well and the solution for us was to remove all tags in our HTML and use css classes with background property instead. Here's an example:

.img_logo {
  background: url(../images/logo.png?v=20150427) no-repeat;
  width: 175px;
  height: 49px;
  display: block;
}

Feels kind of awkward, I know, but this was the only way that solved the problem for us. One drawback is that we had to remove the "alt" for the images but I guess you can solve that with some javascript if necessary.

Hope this helps!


I was dealing with this issue on a new website we just launched. Everything looked good in FF/Opera/Chrome, etc. but I had MAJOR image swapping issues in iOS8+. I noticed that a lot of the sites reporting this problem run Litespeed webserver. I switched to Apache for a moment to test, and sure enough, the website loaded just fine. My host (wiredtree.com, excellent service) and I looked at some of the configuration options in Litespeed, and disabled these two options:

  • Enable Compression
  • Enable Dynamic Compression

After disabling those two, the websites loaded up just fine with no issues. It took a very slight performance hit, but definitely worth it.

At first, we tried to disable keep-alive to effectively disable HTTP Pipelining, but it didn’t solve the problem. The above is the only thing I’ve seen that offered a real solution.

Hopefully this can help someone dealing with the same issues!