Share via

LABS.GENERATIVEAI() Not working (03/2026)

Curtis Bertoldie 0 Reputation points
2026-03-18T02:06:36.49+00:00

I am trying to utilize the ai function in a project at work but something isn't working.

I have both a user and admin key from OpenAI that both start with the "sk-" syntax. I have 365 Premium (personal not business) When I do a simple function like "=LABS.GENERATIVEAI("Hello World")" it just returns with #N/A! error. I'm using the gpt-5 model for Excel Labs

I'm at a loss as to why this isn't working... I have credits in the "vault" of OpenAI and have double checked what seems like every parameter for this to work. I'm also on the beta stream of Excel Labs to access the latest updates and Excel is fully updated, computer has rebooted, and it is still not working.

Any ideas or are others having issues with this working too?

Microsoft 365 and Office | Excel | For home | Windows
0 comments No comments

1 answer

Sort by: Most helpful
  1. Kai-H 14,825 Reputation points Microsoft External Staff Moderator
    2026-03-18T07:46:11.0533333+00:00

    Hi, Curtis Bertoldie

    Sorry for this unwanted experience. This is usually not a Microsoft 365 subscription issue. LABS.GENERATIVEAI is an experimental Excel Labs feature that uses an OpenAI API key, and the real cause of #N/A often shows in the cell’s detailed error message.

    Here are some suggestions you can try:

    Hover over the #N/A cell and check the yellow warning icon. Excel Labs can show the actual failure reason there, such as quota or billing.

    Make sure your OpenAI API billing is active, not just ChatGPT access or old credit. The formula only started working after API billing was enabled.

    Create a new secret key, paste it into Excel Labs again, and fully restart Excel. It is commonly recommended that this helps after billing changes or expired credits.

    If GPT-5 keeps failing, test with another model in Excel Labs Settings. Model choice can be changed, so this helps confirm whether the issue is model-specific.

    In case the issue persists, reinstall/update the Excel Labs add-in and consider opening an issue on the Excel Labs GitHub, since this is a Microsoft Garage experiment and can be rough around the edges.

    Thank you for your patience in reading, I hope this information has been helpful to you. 


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment."    

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread. 


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.