getKeywordPosition

Overview

Get the position of a keyword on the top 100 results of a search engine (Google by default).

Credits cost per execution

This function spends 10 credits per execution

Video example

Arguments

  • keyword: The keyword to get the position

  • languageCode: The language code where to do the search (i.e. en for English)

  • locationName: The location where to do the search (i.e. United States).

    • Check the full list of locations available downloading the CSV depending on the Search Engine

  • domain: The domain to match the position (or if it ranks in the top 100)

Apart from a domain you can select a specific URL to get more granular data.

Optional arguments

  • skipHeader: If true, the first row of the results will be skipped (By default is set to true)

  • searchEngine: The search engine to use (By default is used Google)

  • device: The device to use (By default is used mobile)

  • depth: The depth of the SERP to search (By default is 100)

  • seDomain: The domain of the search engine to use (By default is used google.com)

Expected output

  • Array: The absolute position, the relative to the organic group and the URL ranking for that keyword in the search engine

Text example

getKeywordPosition("seo", "en", "United States", "domain.com", true, "google") 
// organic, absolute, url
// 1 1 "https://www.domain.com/path-1"

Use cases

  • Build your own keyword tracker in Google Sheets

  • Check the position of a keyword in Google Sheets

  • Check if your URL is ranking for a specific query in Sheets

  • Check if your URL is indexed using Sheets

  • Check if you have some content created using Search as a proxy

  • Fix the migration of websites using sheets: find your old URLs and match them with your new ones

Last updated