How to Use the COPILOT() Function in Excel: AI-Powered Formulas

How to Use the COPILOT() Function in Excel: AI-Powered Formulas

Excel now has a built-in COPILOT function that accepts natural language prompts directly in cells. Instead of writing complex formulas, you type a plain English instruction, and Copilot returns AI-generated results that spill into adjacent cells — just like SORT or UNIQUE.

This function works in Excel for Windows and Excel for Mac with a Microsoft 365 Copilot license. Here's how to use it with real examples.

Basic Syntax

The COPILOT function takes a natural language prompt as its first argument:

=COPILOT("Your natural language prompt")

You can add additional arguments to reference cells or ranges that Copilot should use when generating its output.

Excel showing COPILOT function =COPILOT list the five largest employers in the US with results Walmart, Amazon, Kroger, Yum Brands, The Home Depot spilling down with AI-generated label
The COPILOT function returns AI-generated results that spill into multiple cells

Generating Lists with Cell References

The function becomes more useful when you reference other cells. For example, to list the top employers in a specific state:

=COPILOT("list the ten to twelve employers in", C1)

Where C1 contains "FL" (Florida). Copilot returns a spilled list of major Florida employers — Publix Super Markets, Walmart, AdventHealth, Florida Hospital, University of Florida, and more.

Excel COPILOT function referencing cell C1 containing FL to list twelve Florida employers including Publix, Walmart, AdventHealth
Reference cell values to make COPILOT prompts dynamic

Classifying Training Feedback

One of the most practical applications is classification. Given a sheet with training feedback comments and a list of course names, Copilot can map each comment to the correct course:

=COPILOT("list the course for each comment", C3:C11, "based on the courses listed", A3:A6)

Copilot matched "I need PivotTables" to Excel, "I want to learn headers" to Word, "My inbox needs organizing" to Outlook, and "I need to make presentations" to PowerPoint.

Excel spreadsheet with Course, Comment, Name, and Course columns showing training feedback classification setup for COPILOT function
Use COPILOT to classify free-text feedback into predefined categories

Key Features

  • Spilled results — Output automatically spills into adjacent cells, like other dynamic array functions
  • AI-generated label — Results show an "AI-generated" badge with thumbs up/down feedback buttons
  • Dynamic updates — Results recalculate when referenced cells change
  • Multiple arguments — Pass ranges, cell references, and text strings as context for the prompt
  • Hashtag references — Use spilled range references (e.g., B1#) to chain COPILOT results into other formulas

Practical Use Cases

  • Generating lists (top companies, categories, locations) based on cell inputs
  • Classifying open-text survey responses into categories
  • Summarizing or extracting information from text in cells
  • Converting airport codes, state abbreviations, or other codes to full names
  • Brainstorming ideas directly in your spreadsheet

The COPILOT function is part of Excel's calculation engine, so results stay current without running scripts or refreshing add-ins. For more on using Copilot with Excel formulas, see the related guides below.

Excel FORMULA Completion vs COPILOT(): When to Use Each Feature
I use both Formula Completion and the Copilot function in Excel every week. They require a paid Microsoft 365 Copilot license. They solve different problems, and when you combine them, you can move from repetitive calculations to higher-level text analysis and data cleanup in minutes. Below, I explain what each
Excel Formula Completion: How to Extract Zip Codes from Text with REGEXEXTRACT
Excel’s Formula Completion feature can write formulas for you. Just press the equal sign, and Excel suggests the formula based on your data and column headers. In this tutorial, I demonstrate how it works by tackling a common challenge: extracting zip codes from messy address data where the zip code
Financial Ratios - Formula Completion in Excel using Copilot
Writing formulas in Excel can be time-consuming and challenging, even for experienced users. Selecting the right function, referencing the correct cells, and ensuring proper syntax often slows down workflows and leads to errors. Many users spend extra time troubleshooting mistakes, searching for examples, or trying to recall the exact formula
Auto XLOOKUP in Excel: Let Copilot Build Profit Formulas
Excel’s new Formula Completion feature makes writing formulas effortless. Just type the = sign, and Copilot suggests accurate, context-aware formulas.

Want to learn more? Visit courses.chrismenardtraining.com for online training courses.

Read more