The Excel IMAGE function (Excel 365 only) places a picture inside a cell from a web URL. Unlike floating pictures, an in-cell image sorts, filters, and moves with its row — perfect for product catalogues, logos, and dashboards. You control how it fits the cell with four sizing modes, and because it’s a formula, the picture can change based on a lookup.
https URL to a supported format (PNG, JPG, GIF, TIFF, BMP, ICO, WEBP). Resize the cell and the picture follows.
Syntax
| Argument | Description | |
|---|---|---|
source | Required | The https URL of the image. Supported formats: BMP, JPG/JPEG, GIF, TIFF, PNG, ICO, WEBP. |
alt_text | Optional | Alternative text describing the image for accessibility (screen readers). |
sizing | Optional | How the image fits the cell: 0 = fit, keep aspect ratio (default); 1 = fill the cell, ignore ratio; 2 = original size; 3 = custom size from height/width. |
height | Optional | Image height in pixels — only used with sizing 3. |
width | Optional | Image width in pixels — only used with sizing 3. |
Excel 365 only. IMAGE isn’t in Excel 2021 or earlier — older versions show #NAME?. The workbook also needs a connection to fetch the picture.
Worked examples: sizing modes and dynamic pictures
The sizing argument decides how the picture relates to the cell:
| A | B | |
|---|---|---|
| 1 | sizing | Behaviour |
| 2 | 0 (default) | Fit in the cell, keep aspect ratio |
| 3 | 1 | Fill the cell, ignore aspect ratio |
| 4 | 2 | Original size (may overflow the cell) |
| 5 | 3 | Custom size — uses the height and width arguments |
Because IMAGE is a formula, the picture can be looked up. With product names in column A and image URLs in a table:
Try it: build an IMAGE formula
Choose a sizing mode and alt text, and watch the formula take shape with an explanation of what Excel will do with the picture.
Requirements, and IMAGE vs Picture-in-Cell
IMAGE has firm requirements:
- https only —
http://sources and local file paths (C:\...) are rejected with #VALUE!. To use a local picture, upload it somewhere web-accessible (SharePoint/OneDrive shared links can work if directly downloadable) or use Insert > Pictures > Place in Cell instead. - Supported formats — BMP, JPG/JPEG, GIF, TIFF, PNG, ICO, WEBP. SVG is not supported.
- A live connection — Excel fetches the image; offline, cells may show #CONNECT! or a placeholder until reconnected.
IMAGE vs “Place in Cell”: Insert > Pictures > Place in Cell embeds a static local picture in a cell with no formula and no URL needed. Use IMAGE when the picture should be computed — driven by lookups, switched by dropdowns, or generated from a URL pattern like ="https://cdn.example.com/" & A2 & ".png".
Errors & common pitfalls
#VALUE! — bad source or arguments. The URL isn’t https, points to an unsupported format (e.g. SVG or an HTML page), or sizing/height/width are invalid (sizing must be 0–3; height/width only apply with 3).
#BLOCKED! — security settings. Your organisation’s policies or Trust Center settings block linked data types/external content, or the file is in a location where external content is disabled.
#CONNECT! / #BUSY! — fetching problems. Excel can’t reach the URL (offline, firewall, dead link), or is still downloading. #BUSY! usually resolves by itself.
#NAME? — older Excel. IMAGE only exists in Excel 365 (and Excel for the web). Anyone opening the file in Excel 2021 or earlier sees #NAME?.
Pitfall: URLs that aren’t direct images. A link to a page containing the picture fails — the URL must return the image file itself. Test by pasting the URL in a browser: you should see only the picture.
Practice workbook
Frequently asked questions
Which Excel versions have the IMAGE function?
Can IMAGE use a picture from my computer?
source must be an https URL. For local pictures use Insert > Pictures > Place in Cell, which embeds the image in a cell without a formula, or host the file somewhere web-accessible first.What do the sizing modes mean?
How do I make the picture change based on a dropdown?
=IMAGE(XLOOKUP(A2, Products[Name], Products[ImageURL]), A2). Changing the dropdown in A2 swaps the picture instantly.Why does IMAGE show #BLOCKED!?
Master functions like this in one day
This page covers one function. Our Excel Formulas and Functions class covers the 30 that matter most — live, hands-on, taught by professionals in Dallas–Fort Worth, Houston, Austin, Oklahoma City, Denver, or online.
See the Formulas & Functions Class