Microsoft just announced new feature for Python in Excel that lets you analyze images in your spreadsheets. You no longer need outside tools—you can manipulate, analyze, and pull information from images directly in Microsoft Excel on Windows, Mac, and the web.

All you have to do is drop an image into a cell and run Python code on it. In an example given by Microsoft, an image was placed in a cell using the standard insert method of “Insert > Illustrations > Pictures > Place in Cell.” Then, Python code was made to check to see how blurry or sharp an image is, as well as convert it to grayscale. To do the code, type=PY()into a cell, then use a code block like this example from Microsoft:

Make sure to press Ctrl+Enter or the code won’t work. The example checks how much detail is in an image by using a special filter known as a Laplacian filter. If there’s not a lot of variation, the image is probably blurry, but if not, it’s likely sharp.

According to the company, the Pillow library is currently the most useful one available for image analysis with Python in Excel. It gives you a ton of tools for processing images, including pixel-level access, transformations, and metadata extraction. To make sure everything runs smoothly and you don’t run into any data limits, you can adjust the image size settings.

By going to “File > Options > Advanced > When calculating this workbook > Python in Excel,” you can choose to resize images to actual size, large (1280x960), medium (640x480), or small (320x240). This is super helpful because if you go over the per-cell data limit, you’ll see an error that tells you how to adjust your settings.

There’s more to this update than just showing if an image is blurry. With Python, you can also do some serious image manipulation without the need for Photoshop. You can do things like adjust brightness, change colors, or even watermark product images. The more tech-savvy can also dive into metadata analysis and create plots to explore the structure and composition of an image.

I think this would be best for someone who deals with large numbers of images and needs to process them in bulk. If you’re going to edit individual images once in a while, then you may as well use a photo-editing app unless you really need all the information.

This isn’t the first big updatewith Python, but bringing images into the mix is a huge step forward. The feature is currently available for those who have access to Python in Excel and are running specific versions of Windows (Version 2509 or later) or Mac (Version 16.101 or later). For those using Excel for the web, it’s in the process of rolling out, so you should expect to see it soon.