title: Get Image size from URL
body: <p>I have a list of URIs of images from essentially a Wordpress site. 
  I want to be able to have a script to get their file sizes (mb, kb, GB) from just using the URIs.
  I don't have access to this server-wise and need to add the sizes to a Google sheet. This seems like the fastest way to do it as there are over 5k images and attachments.  </p>
  
  <p>However when I do this in Python </p>
  
  <pre><code>&gt;&gt;&gt; import requests
  &gt;&gt;&gt; response = requests.get("https://xxx.xxxxx.com/wp-content/uploads/2017/05/resources.png")
  &gt;&gt;&gt; len(response.content)
  3232
  </code></pre>
  
  <p>I get <strong>3232 bytes</strong> but when I check in Chrome Dev Tools, it's <strong>3.4KB</strong> </p>
  
  <p><a href="https://i.stack.imgur.com/af4b5.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/af4b5.png" alt="enter image description here"></a></p>
  
  <p>What is being added? Or is the image actually <strong>3.4KB</strong> and my script is only checking content-length? 
  Also, I don't want to check using the <code>Content-Length</code> header as some of the images may be large and chunked so I want to be sure I'm getting the actual file size of the image.</p>
  
  <p>What is a good way to go about this? I feel like there should be some minimal code or script I could run. </p>