SheetMagicSheetMagic

5 Ways to Use AI for SEO in Google Sheets and Save Hours

Use AI for SEO in Google Sheets: pull search results at 1 credit a search, audit competitor pages, write 200 meta descriptions with one formula, and track Google rankings at 3 credits a keyword. Hours of tab-switching become a sheet you rerun.

Phil Nguyen · 13 min read · Updated

To use AI for SEO in Google Sheets, pair scraping formulas that pull search results and page tags into cells with =AITEXT(), which classifies, compares, and writes from those cells. The payoff is hours: 200 meta descriptions from one dragged formula, and a weekly rank check that is one re-dragged column instead of 50 searches.

Your spreadsheet is already an SEO tool. You just need the right formulas.

Say you are a freelance SEO with five client sites. Every week you check 50 priority keywords by hand, about a minute each, so 50 minutes. Every new site launch needs meta descriptions, and at about 2 minutes each, 200 pages is 6 hours 40 minutes of writing.

If you do SEO, you live in spreadsheets. Keyword lists, rank tracking, content calendars, link audits. It all ends up in rows and columns. The problem is that the fun work (analyzing competitors, writing meta descriptions, building content briefs) usually happens somewhere else. ChatGPT in one tab. Ahrefs in another. A Google search in a third.

SheetMagic brings all of that into one place. The five methods below are exact formulas you can paste into your sheet right now. Each one replaces a manual process that would normally take hours.

If you are new to SheetMagic, start with the getting started guide to install the add-on and run your first formula.


1. Pull live SERP data for any keyword with =SERP()

Most keyword research starts with a search. You type a term, scan the results, and write down titles, URLs, and snippets by hand. (If you have tried this with IMPORTXML, here is why it breaks on search pages.) With =SERP(), you skip that manual part entirely. =SERP() runs on DuckDuckGo, costs 1 scraping credit per search, and is the right tool for finding who covers a topic. When you need Google specifically, use =GSEARCH().

Set up your sheet:

  • Column A: your seed keywords
  • Column B: the SERP formula

Formula

=SERP(A2)

Returns up to 20 structured DuckDuckGo results for the keyword in A2: titles, snippets, and URLs, in result order.

That single formula returns structured data for up to 20 results per keyword, spilling down and across from the formula cell. Give each =SERP() its own empty block, or use =BULKSERP() below for a whole keyword list. No browser needed.

Take it further with =BULKSERP():

Formula

=BULKSERP(A2)

Returns search results in a horizontal layout -- one row per keyword, with results spread across columns. Easier for comparing multiple keywords side by side.

=BULKSERP() lays results out horizontally instead of vertically: one row per keyword, 5 results by default as title, snippet, and URL triples. Because each keyword takes one row, you can drag it down column B for your entire keyword list.

For the larger build, including geo-targeted pulls and result pagination, see bulk SERP scraping in Google Sheets.

Tip

=SERP() and =BULKSERP() run on DuckDuckGo and cost 1 scraping credit per search, with no AI tokens, on any plan. Scraping credits are also spent by scraping formulas like =VISIT() and =GETMETATITLE(). The free tier includes 100 of them (a one-time allowance that never expires or renews), and paid plans start at 10,000 credits/month. Check the pricing page for details.

Cluster keywords by search intent with =AITEXT()

Once you have SERP data, use =AITEXT() to classify each keyword by intent:

Formula

=AITEXT("Classify this keyword by search intent. Return exactly one label: informational, navigational, transactional, or commercial investigation. No explanation.", A2)

Returns a single intent label for the keyword in A2. The no-explanation constraint keeps the output clean for filtering.

Now you can filter your keyword list by intent. Sort by "transactional" to find money keywords. Filter "informational" to plan blog content. This turns a flat keyword list into a prioritized content strategy.


2. Analyze competitor content without leaving your sheet

Here is the workflow: scrape the top-ranking pages for your target keyword. Extract their content structure. Then use AI to find the gaps your content should fill.

01

Pull the top-ranking URLs

Start with =SERP() to get the URLs ranking for your target keyword. You already have these from step 1.

02

Extract each page's meta title and description

Use the dedicated meta extraction formulas. Put competitor URLs in column A:

=GETMETATITLE(A2) in column B

=GETMETADESCRIPTION(A2) in column C

03

Pull the heading structure

Extract the H1 and H2 tags to see how competitors organize their content:

=GETH1(A2) in column D

=GETH2(A2) in column E

04

Scrape the full page content

For deeper analysis, pull the full page text:

=VISIT(A2) in column F

This grabs up to 50,000 characters of page content.

05

Run AI analysis on the competitor data

Now use =AITEXT() to analyze what you have collected:

=AITEXT("Based on this page content, list the 5 main topics covered and identify one topic gap that a competing article could fill. Be specific.", F2)

The result is a competitor analysis spreadsheet that would normally take a full afternoon to build by hand, and every cell is formula-driven. For a different keyword, paste its competitor URLs into column A of a copy of the tab and drag the formulas down again.

Formula

=AITEXT("Compare these competitor meta descriptions and identify what makes the strongest one effective. Then write a better one that is under 155 characters. Descriptions: "&C2&" | "&C3&" | "&C4&" | "&C5, B2)

Feeds multiple competitor meta descriptions into one prompt and generates a superior version based on the page title in B2.


3. Generate meta descriptions and title tags at scale

Writing unique meta descriptions for hundreds of pages is one of the most boring tasks in technical SEO. Here is how to do it with one dragged formula.

Sheet layout:

  • Column A: page URL
  • Column B: =GETMETATITLE(A2) (pull existing title)
  • Column C: =GETH1(A2) (pull the H1 for context)
  • Column D: target keyword (enter this yourself or grab it from your keyword sheet)
  • Column E: new meta description (the formula below). With Keep Formula on (the default), the formula stays in E as text and the description lands in F, so keep F empty

Formula

=AITEXT("Write a meta description for this page. Rules: under 155 characters, include the keyword """&D2&""" naturally, end with a clear call to action. Page title: "&B2&". Main heading: "&C2, "")

Generates a keyword-optimized meta description using the existing page title and H1 as context. The tripled quotes around D2 put the keyword into the prompt wrapped in quote marks.

Why this works better than generic meta description generators: The formula uses the actual page title and H1 as context. So the AI writes descriptions that fit the specific page content, not just the keyword.

For title tags, use a similar approach:

Formula

=AITEXT("Write an SEO title tag under 60 characters for a page about "&C2&". Include the keyword """&D2&""" near the beginning. Make it compelling for search results.", "")

Generates a click-worthy title tag that fits within Google's display limits.

Tip

Test one row first. Review the output. Tweak the prompt if needed. Then drag down to generate descriptions for your entire site. For more prompting strategies, see the complete AI formulas guide.


4. Build content briefs that writers can actually follow

The gap between "we need an article about X" and a published piece is usually a content brief. Most briefs are either too vague (a keyword and a word count) or take forever to write. SheetMagic can generate detailed briefs in seconds.

Step 1: Gather the raw inputs.

Set up columns for the target keyword, the top-ranking URLs (from =SERP()), and the heading structures of competing articles (from =GETH2()).

Step 2: Generate the brief.

Formula

=AITEXT("Create a content brief for an article targeting the keyword """&A2&""".\n\nInclude:\n- Target audience (be specific)\n- Search intent\n- Recommended word count\n- 6-8 suggested H2 headings\n- 3 key points each heading must cover\n- Internal linking suggestions\n- One unique angle competitors are not covering\n\nCompetitor headings for reference: "&D2, "")

Generates a detailed content brief using the target keyword and competitor heading data as inputs. The \n markers are plain text in a Sheets formula; the AI reads them as line breaks.

Each brief lands in a single cell. You can wrap the column to display the full text, or copy the cell contents into a Google Doc for your writers.

Step 3: Generate a meta description and title tag for the planned content.

Use the formulas from section 3 above. Point them at the brief content instead of an existing page. This means your writers have SEO-ready metadata before they even start writing.

Note

Content briefs work best with models that handle long output well. Claude and GPT-4o both produce strong briefs. You can switch models in the SheetMagic settings under Extensions > SheetMagic without changing your formulas. See all supported providers.


5. Monitor your rankings and track changes over time

This is where the spreadsheet format really shines. Because search results come back live, you can build a rank tracking system that updates on demand.

Use =GSEARCH() here rather than =SERP(). Rank tracking only means something against the engine you actually care about, and =GSEARCH() returns real Google positions, 10 organic results per call, for 3 scraping credits. It also takes a country code, so you can track a market rather than a default locale.

=GSEARCH() runs in the background. The cell shows ⏳ Scraping..., then the results land in their own tab named Google Search Results. With Keep Formula on (the default), the formula cell keeps your formula as text; with it off, the cell changes to a line like ✅ 10 results → Google Search Results. In that tab, column A (Source) names the cell that asked, column B is Position, and column D is the URL. Drag =GSEARCH() down a column and every keyword's results collect in the same tab.

Sheet layout:

  • Column A: your target keywords
  • Column B: your domain (e.g., "sheetmagic.ai")
  • Column C: =GSEARCH(A2, "us") (pull current Google results)
  • Column D: your position, looked up from the results tab with the formula below

Formula

Finds the first result in the Google Search Results tab that was requested from C2 and whose URL contains your domain, and returns its position. No AI tokens, since a lookup is plain spreadsheet work.

To track changes over time:

  1. Before each weekly run, copy column D into column E as values (Edit > Paste special > Values only)
  2. Put =GSEARCH(A2, "us") back in C2 and drag it down. Once results land, the cell holds the formula as text (Keep Formula on) or the status line (Keep Formula off), so it has to be re-entered to run again
  3. Each run writes a new tab, such as Google Search Results (2). Point the lookup formula at that tab name, then subtract to see the movement

Formula

=IF(ISNUMBER(D2)*ISNUMBER(E2), E2-D2, "")

Positive means you moved up that many positions since last week, negative means you dropped. Put last week's positions in column E.

This is not a replacement for dedicated rank tracking tools if you need daily monitoring of thousands of keywords. But for tracking 50 to 200 priority keywords on a weekly basis, it is faster to set up. At 3 credits a keyword, 50 keywords a week is 150 credits, about 600 a month, which fits inside Solo's 10,000 monthly credits.


What can you do with the SEO data once it is in your sheet?

The time back is the headline: about 6 hours 40 minutes on 200 meta descriptions, and about 50 minutes a week on rank checks. The rows also change which work you do next:

  1. Write the article that can earn money first. Filter the intent column for "transactional" and the rank column for "Not ranking". What is left is the list of buying-intent keywords where you have no page in the top 10, which is a better next brief than whatever is next in the content calendar.
  2. Ship the meta descriptions in one import. Section 3 leaves a new description beside every URL. Most CMS and SEO plugins accept a CSV import, so the column goes live without anyone pasting 200 fields into 200 edit screens.
  3. Catch a drop the week it happens. Sort the movement column ascending. A page that fell 6 places shows up as -6 at the top, and you can refresh it before the slide shows up as lost leads in next month's report.
  4. Send clients a report, not a promise. Share the rank tab with each client. The work you already did for yourself becomes the weekly deliverable, with no extra hours spent formatting a PDF.

The complete SEO spreadsheet system

Here is what makes this approach so useful: everything connects. Your keyword research (step 1) feeds into your competitor analysis (step 2). Your competitor analysis shapes your meta descriptions (step 3) and content briefs (step 4). Your rank tracking (step 5) tells you if your published content is working. That feeds right back into your keyword research.

It is a closed loop. And it all lives in one spreadsheet.

Formulas used in this guide:

FormulaPurposeUses
=SERP()Pull live search results1 credit per search
=BULKSERP()Horizontal SERP layout1 credit per search
=GETMETATITLE()Extract page title tagsScraping credits
=GETMETADESCRIPTION()Extract meta descriptionsScraping credits
=GETH1() / =GETH2()Extract heading structureScraping credits
=VISIT()Pull full page contentScraping credits
=GSEARCH()Real Google positions3 credits per search
=AITEXT()Generate and analyze textAI tokens

Note

Web scraping formulas like =VISIT() use scraping credits. AI formulas (=AITEXT()) use AI tokens. These are separate quotas tracked independently in your plan. Search with =SERP() and =BULKSERP() uses scraping credits (1 per search) and no AI tokens. The free tier includes 20,000 AI tokens and 100 scraping credits (a one-time allowance that never expires). Check pricing for paid plan limits.

For a deeper dive into web scraping formulas, read the complete web scraping guide. For more AI formula techniques, see how to use AI formulas in Google Sheets.

Text and scraping formulas run on the free allowance. Install from the Google Workspace Marketplace, no card, no expiry.

Install free for Google Sheets

About the author

Phil NguyenPhil builds SheetMagic, the Google Sheets add-on that brings AI and web scraping into the spreadsheet, used by 6,300+ people. He writes these guides from the formulas he runs on his own sheets.