8 Ways To Insert an Image in Microsoft Excel

Find out how to insert images in Excel using various proven methods that involve user interface commands, functions, and programmatic tools.

Beyond its reputation as a powerful tool for crunching numbers and creating charts, Excel can also function as a surprisingly effective image database. Whether you’re managing product photos for an online store or storing employee headshots, Excel provides a convenient and accessible solution.

If you’re new to working with images in Excel or simply seeking fresh approaches, the following techniques will walk you through with clear steps and visual illustrations.

Using the Illustrations Commands

Illustrations commands block
Illustrations commands block

The Illustrations block of the Insert tab of the Excel ribbon menu is the hub for attachment commands. These tools allow you to insert external images, graphics, vectors, icons, shapes, etc., from the local PC storage or online locations. These commands are as outlined below:

  • Pictures
  • Shapes
  • Icons
  • 3D Models
  • SmartArt
  • Screenshot

You can use most of the above commands to insert custom or default images.

For example, let’s see below how to use the Pictures command to insert an image in the worksheet.

Pictures command options
Pictures command options

When on the target worksheet, click on the Insert tab and then click the Pictures drop-down menu.

You’ll see two options, as explained below:

  • Place in Cell: It lets you insert an image in a cell in Microsoft Excel. The image is initially scaled down to fit the cell. However, if you increase the cell dimensions, the picture will scale up automatically.
  • Place over Cells: This option allows you to place the attached image as an Excel object on top of the cells. You can freely move, resize, and edit the image using mouse clicks.
Insert Picture From
Insert Picture From

Once you see the Pictures context menu, hover the mouse over the Place over Cells menu to open the Insert Picture From overflow menu.

Here, you can see the sources from which you can import an image or graphics to your worksheet. In the latest Excel for Microsoft 365 desktop app, the following sources are visible:

  • This Device: It opens a file browser so you can select an image from the local storage.
  • Mobile Device: This option allows you to sync your Android or iOS smartphones with the Phone Link app from Microsoft. Then, you can browse your mobile phone’s images directly from the Excel desktop app.
  • Stock Images: It takes you to Microsoft’s creative visual content library, hosting hundreds of images and graphics in genres, like Icons, Images, Cutout People, Stickers, Illustrations, and Cartoon People.
  • Online Pictures: This option opens a Bing image search interface for random, pictures from random online sources.
This Device
This Device

Let’s say, you want to add an image from your PC. Choose This Device.

Insert Picture dialog
Insert Picture dialog

Navigate to the source image on the device using the Insert Picture dialog. Select the file and click on the Insert button at the bottom.

Insert image in Excel using Pictures command
Insert image in Excel using Pictures command

Excel will import the image instantly.

In another instance, you want to insert a website’s or software interface’s screenshot as a picture in the worksheet.

First, open the source window, like a website’s home page.

Now, press Alt + Tab once, twice, or as needed to navigate to the target worksheet. Please note the source website should be the next open window when you minimize Excel’s window. You must arrange windows this way because the Excel Screenshot tool doesn’t allow browsing through the open windows.

Screen Clipping
Screen Clipping

Go to Insert > Illustrations > and click on the Screenshot drop-down menu.

Select the Screen Clipping option from the context menu.

Screen clipping interface
Screen clipping interface

The Excel desktop app window will be minimized. The source website window will open with an overlay and the mouse cursor will also change to a crosshair.

Using crosshair to crop desired area
Using crosshair to crop desired area

Use the crosshair to crop a part of the source window to grab the image.

Insert a picture as screenshot in Excel
Insert a picture as screenshot in Excel

The cropped area will be inserted as a picture in Excel.

Insert Image Using the Camera Tool

You can use the Microsoft Excel Camera command to insert dynamic images from another Excel worksheet. The source worksheet could be in the same workbook or in a separate Excel file.

The image you add this way changes as the source dataset gets updated. So, if creating a business or personal productivity dashboard by referencing multiple Excel workbooks, try this technique.

It allows for visual snapshot creation from referred worksheets and workbooks without using Excel functions or pulling data from another sheet.

Enabling the Camera Tool

The Camera command has been available since Excel 2007. The tool isn’t readily accessible using the Excel ribbon menu. You must add it in the Quick Access Toolbar.

QAT More Commands
QAT More Commands

Click on the QAT drop-down menu in the top left corner of Excel.

Choose the More Commands option from the context menu.

QAT customization
QAT customization

Click on the Popular Commands drop-down menu and choose All Commands.

Find the Camera tool in the left-side list of items and select it.

Click Add to move the Camera command to the QAT list on the right side.

Click OK on the Excel Options dialog box to save this change.

Camera command
Camera command

The Camera tool will show up near the QAT area in the top left corner.

Using the Camera Tool

Creating a dynamic snapshot as an image of another worksheet using the Camera tool is a bit tricky. Let me simplify the process for you below.

Select range and click Camera
Select range and click Camera

Go to the source worksheet and select the cell range for which you want to create an auto-updating image.

Click on the Camera tool in QAT.

Now, navigate to the target worksheet where you want to place this image.

Draw rectangle in destination
Draw rectangle in destination

Use the crosshair to draw a rectangle near the destination cell range.

Inserted image using Camera
Inserted image using Camera

Excel will insert the dynamic image in the designated area.

Resizing Camera image
Resizing Camera image

You can resize the image by dragging its edges using the mouse cursor.

Using the Object Command

Often, you need to add custom-drawn pictures in Excel from the Microsoft Paint app or Adobe Photoshop. The Object tool can help you with this.

Object tool
Object tool

Go to the destination worksheet and open the Object tool from Insert > Text.

Bitmap Image
Bitmap Image

The Object dialog will open. Here, you can choose the Excel Object you want to create by choosing an item from the Object type list.

To insert custom-drawn images, choose Adobe Photoshop Image 15 or the Bitmap Image option.

For example, let’s select the Bitmap Image option. Click OK.

Paint app on Excel
Paint app on Excel

A miniature interface of the Paint app will open. You’ll also see a blank placeholder for an image in the worksheet.

Drawing shapes on Paint
Drawing shapes on Paint

Now, whatever you draw in the Paint app will show up instantly in the image object. If you make edits in the Paint app, that will be updated as well.

Insert Image using Object
Insert Image using Object

Close the Paint app to complete adding the custom-drawn image.

Using a Microsoft 365 App

You can copy an image from most Microsoft 365 apps and paste it on an Excel worksheet as an image object.

Let’s consider the picture you want to insert in your worksheet is in a Microsoft Word document.

Copy image from Word
Copy image from Word

Open the DOCX file and copy the picture by pressing Ctrl + C.

Paste image in Excel
Paste image in Excel

Go to the destination worksheet, select a cell, and press Ctrl + V.

Using the IMAGE Function

You can use the IMAGE function to insert a picture from the internet into an Excel cell.

For example, you’d like to add the image found in the following hyperlink in B2.

https://www.howtoexcel.org/wp-content/uploads/2024/06/Save-AutoRecover-information-every.png
Using IMAGE function
Using IMAGE function

In the destination cell, enter the following formula and hit Enter:

=IMAGE("https://www.howtoexcel.org/wp-content/uploads/2024/06/Save-AutoRecover-information-every.png","Picture",2)

In the above formula, the only mandatory argument is the image URL within double quotes. However, you can also add other optional arguments, like Alt Text, Image Size, etc.

Once you enter the URL and enter a comma, Excel will show all optional arguments in square brackets.

I’ve added Picture as the alt text and 2 for the original image size.

Insert image using a function
Insert image using a function

Excel will add the image if the URL is valid and if the workbook allows online content rendering.

This method is limited to Excel 2021, Excel for Microsoft 365 desktop, and Excel for the web app. Also, The URL you’re rendering must show the image file extension, like JPG, PNG, etc. If the URL requires a sign-in, Excel won’t be able to render the picture.

Insert Images as a Header or Footer

Excel allows attaching pictures also as worksheet headers and footers.

Page Layout view
Page Layout view

To try out this technique, go to the View tab and click on the Page Layout view mode inside the Workbook Views block.

Click on header placeholder
Click on header placeholder

You should enter the header and footer view. Click on the Add header placeholder to activate the Header & Footer tab in the Excel ribbon.

Insert pictures form
Insert pictures form

Go to the Header & Footer tab and click on the Picture command inside the Header & Footer Elements block.

The Insert Pictures form will show up. There, you’ll see the following three sources:

  • From a file
  • Bing Image Search
  • OneDrive – Personal
Insert image dialog
Insert image dialog

For example, select From a File and choose an image from the local storage. Click Insert to add the picture.

Picture code in Header
Picture code in Header

You’ll see the &[Picture] code inside the Add header placeholder.

Insert image as header in Excel
Insert image as header in Excel

Click anywhere else on the page layout view to render the header image.

Using Excel VBA

Instead of performing multiple manual steps to insert an image, you can use a simple Excel VBA macro to automate the entire process.

I’ve created a short VBA script that will walk you through the workflow with visual dialog boxes. However, first, you need to learn the process of creating a VBA macro from this quick Excel tutorial:

๐Ÿ“’ Read More: How To Use The VBA Code You Find Online

Now, use the following script in your macro:

Excel VBA script
Excel VBA script
Sub InsertImage()
    Dim imgPath As String
    Dim img As Picture
    Dim cell As Range
    Dim inCell As String
    
    ' Show file dialog to select image
    With Application.FileDialog(msoFileDialogFilePicker)
        .Title = "Select Image"
        .Filters.Add "Images", "*.jpg; *.jpeg; *.png; *.bmp; *.gif", 1
        If .Show = -1 Then
            imgPath = .SelectedItems(1)
        Else
            Exit Sub
        End If
    End With
    
    ' Show input box to ask if image should be inserted in the cell
    inCell = InputBox("Do you want to insert the image in the cell? (Yes/No)", "Insert Image")
    
    ' Get the active cell
    Set cell = ActiveCell
    
    ' Insert image based on user input
    If LCase(inCell) = "yes" Then
        ' Insert image in the cell
        Set img = cell.Worksheet.Pictures.Insert(imgPath)
        With img
            .Left = cell.Left
            .Top = cell.Top
            .Width = cell.Width
            .Height = cell.Height
            .Placement = xlMoveAndSize
        End With
    Else
        ' Insert image over the cell
        Set img = cell.Worksheet.Pictures.Insert(imgPath)
        With img
            .Left = cell.Left
            .Top = cell.Top
            .Placement = xlFreeFloating
        End With
    End If
End Sub

Once you’ve created the above macro, press Alt + F8 to open the Macro dialog box.

Click on the InsertImage macro inside the list of available macros and hit the Run button.

Select input image
Select input image

You’ll see a file browser so you can select the input image.

Insert image VBA dialog
Insert image VBA dialog

Now, Excel will ask you whether you want to place the picture within the cell or over the cell.

If you type Yes and hit Enter, Excel will insert the image into the active cell on the worksheet.

Inserted image in worksheet using VBA
Inserted image in worksheet using VBA

Contrarily, if you select No, Excel will place the image in its original size over the selected cell.

You can now resize the image as required.

Using Office Scripts

You can also use the latest Excel automation language, Office Scripts, to automatically add an image in Excel. You can run an Office Scripts automation locally on the Excel for Microsoft 365 desktop and Excel for the web apps. Or, you can integrate the script in Power Automate to run it without even opening the Excel file.

Automate tab
Automate tab

On your worksheet, navigate to the Automate tab. You’ll find this tab if you’re using Business Standard or a better subscription for Microsoft 365.

In Automate, find and click on the New Script command.

The Office Scripts Code Editor panel will open on the right side.

Save script
Save script

Delete any existing script from the Code Editor and enter the following script.

function main(workbook: ExcelScript.Workbook) {
  // Get the active worksheet
  let sheet = workbook.getActiveWorksheet();

  // Get the URL from cell A2
  let imageUrl = sheet.getRange("A2").getValue() as string;

  // Construct the IMAGE function formula
  let imageFormula = `=IMAGE("${imageUrl}")`;

  // Set the formula in cell B2
  sheet.getRange("B2").setFormula(imageFormula);
}

Click on the Save script button to save it for the future. You can give the script a custom name if you like.

Now, hit Run to execute the script.

Added image using Office Scripts
Added image using Office Scripts

The Office Scripts code will fetch an image URL from A2 and render it as a picture in B2.

The input image hyperlink must show the image file’s extension at the end, like the one shown below.

Conclusions

So far, you’ve gone through the tried and tested methods to insert images in Excel from various sources. You can pick one or more methods according to your worksheet’s requirements.

Use manual methods, like the Illustrations tools, the Camera command, and the IMAGE function for occasional needs.

If you need to do this frequently for a large worksheet, use automated methods, like Excel VBA and Office Scripts.

Comment below to share acknowledgment if you’ve found the Excel tutorial useful. If I’ve missed a popular method you know of, mention that in the comment box.

About the Author

Bipasha Nath

Bipasha Nath

Bipasha is a technical content writer with 10+ years of experience in the technology industry. She previously worked in a SaaS software development company focused on SharePoint, OneDrive, Word, Excel, Word solutions.

Related Posts

Comments

0 Comments

Submit a Comment

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Get the Latest Microsoft Excel Tips

Follow Us

Follow us to stay up to date with the latest in Microsoft Excel!

Subscribe for awesome Microsoft Excel videos ๐Ÿ˜ƒ