title: SVG file size limits for iOS Safari
body: <p>I am developing a mobile website which uses an IMG tag to display an SVG file. The SVG file is about 500 kB. The image renders OK in Android versions of Firefox and Chrome. However, in iOS Safari, I get only the dreaded tiny blue box with a question mark in it.</p>
  <p>I am aware that there is a limit on the size of image files in iOS. According to Apple's <a href="http://developer.apple.com/library/safari/#documentation/AppleApplications/Reference/SafariWebContent/CreatingContentforSafarioniPhone/CreatingContentforSafarioniPhone.html#//apple_ref/doc/uid/TP40006482-SW15" rel="noreferrer">Safari Web Content Guide</a>:</p>
  <blockquote>
  <p>The maximum size for decoded GIF, PNG, and TIFF images is 3 megapixels for devices with less than 256 MB RAM and 5 megapixels for devices with greater or equal than 256 MB RAM.</p>
  <p>That is, ensure that width * height ≤ 3 * 1024 * 1024 for devices with less than 256 MB RAM. Note that the decoded size is far larger than the encoded size of an image.</p>
  </blockquote>
  <p>I imagine that there is some limit on the size of SVG files, but since they are vectorized, it doesn't really make sense to describe their size in terms of decoded pixels. Does anyone know how the limit on SVG files is determined?</p>
  <p>P.S. When I put browse the SVG file directly instead of through an HTML page, I am able to view the image. I am also able to view the SVG file inside of an IFRAME. But not using the IMG tag.</p>