IMAGE Function – Google Sheets

The IMAGE function lets a spreadsheet user insert an image into a cell. The source of the image is specified as a URL.

Syntax

=IMAGE(url,[mode],[height],[witdth])

  • url – The location of the image on the web – (“https://www.wheremypicis.com/mypic.png”). You must either use quotation marks around the URL or put it in another cell and reference it.
  • [mode] – Optional specification of how to size the image.
    • 1 – Resize to fit the cell. Maintains the same aspect ratio so the image does not look distorted.
    • 2 – Makes the image fit the entire cell. Will disregard the aspect ratio.
    • 3 – Maintains original size even it gets cropped.
    • 4 – Custom
  • [height] – If you specify 4 for custom mode, use this for the height.
  • [width] – If you specify 4 for custom mode, use this for the width.

Errors

#N/A – Not enough arguments. Possibly because you used option #4 but did not specify height and width.

Examples

 Live examples in Sheets

Go to this spreadsheet for examples of the IMAGE function shown above that you can study and use anywhere you would like.

0 thoughts on “IMAGE Function – Google Sheets

  • Based on a number in a cell (0-9) I want to display a particular image in another cell.
    Your example only shows if a number is higher or lower than a particular number.
    Can you expand beyond two image location references to ten in my case?
    Any help would be much appreciated

  • Hello,

    I have images saved on my google drive that I’d like to use an =IF(A2>=B2,IMAGE(“URL”),””) function on a google sheet.

    Is there a way I can link this cell to images saved in google drive? Or how would I go about linking these custom images?

    Thank you!

    • Adam Steinfurth says:

      I doubt it would work or if it did, it may stop working later. If you want to try it, maybe try the share functionality, get shareable link, make it public, and let us know how it goes.

    • I tried to link to Google Drive, Dropbox, and Box images. Nothing worked. So I published them to a Blogger blog and got the URL from there.

  • Hi, I would like to know if the image formula still working on… my cell with this formula is about a half has no picture in it… but the url is good if I just type it in chrome, thanks!

      • Does it download and put it in the sheets or does it fetch the image from the URL everytime you open the sheet? I’m using an API to get an image but the image would change depending upon when I make the request

  • What if my URL consists of https://“blabla”.png ?
    This does not work with the =IMAGE formula since I need to put “” inside the parenthesis which then interferes with the URL if the URL already has “”.
    Help please.

  • I’m trying to get my images to display in Sheets from a link posted in another cell. For example, I have an image link in C1 (http://imagelink.png), and am trying to display it in D1 using the =image function. Do you know how I could do this?

    • Adam Steinfurth says:

      Not sure. Maybe integrate the TEXT function somehow. I’m assuming you tried a simple cell reference? Like typing =C1 in to D1.

  • Can you have a drop down reference in the URL of the IMAGE function?

    =IF($I6>0,IMAGE(“http://bilder.stefanborg.se/allsvenskan/teams/AIK/7.png”, 3),””)

    In the example above I would like to have the part that says AIK to be pulled from the drop down so when I choose another team it change the images to match the new team selected.

  • PLEASE HELP:
    i have an appsheet APPLICATION with a column for signature, when i try it, the signatures appear as IMAGE url in google sheets. HOW DO I DISPLAY THESE IMAGES IN GOOGLE SHEETS.???????

  • Hello, I am attempting to use forms to create an inventory with images, but so far, I am only able to add the link for each image. I have my images divided into separate folders on my google drive. Is it possible to convert that link to fill the cell after it is uploaded to sheets?

Leave a Reply

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

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>