AutomationFlowsData & Sheets › Track Website Traffic with Semrush API and Log Results to Google Sheets

Track Website Traffic with Semrush API and Log Results to Google Sheets

BySk developer @skdeveloper on n8n.io

This workflow uses the Website Traffic Checker Semrush API to analyze website traffic and performance. It collects data through a user-submitted website URL and stores the results in Google Sheets for easy access and reporting. Ideal for SEO analysis and data tracking.

Event trigger★★★★☆ complexity9 nodesForm TriggerGoogle SheetsHTTP Request
Data & Sheets Trigger: Event Nodes: 9 Complexity: ★★★★☆ Added:

This workflow corresponds to n8n.io template #7459 — we link there as the canonical source.

This workflow follows the Form Trigger → Google Sheets recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "55979fca-6abb-43f2-af9a-59f2cacaeb51",
      "name": "On form submission",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        0,
        0
      ],
      "parameters": {
        "options": {},
        "formTitle": "website traffic checker",
        "formFields": {
          "values": [
            {
              "fieldLabel": "website",
              "requiredField": true
            }
          ]
        },
        "formDescription": "website traffic checker"
      },
      "typeVersion": 2.2
    },
    {
      "id": "00963262-4328-4998-a996-b12d98f1badb",
      "name": "Re format output",
      "type": "n8n-nodes-base.code",
      "position": [
        560,
        0
      ],
      "parameters": {
        "jsCode": "return $input.first().json.data.semrushAPI.trafficSummary[0]"
      },
      "typeVersion": 2
    },
    {
      "id": "47be20f6-5340-4d42-af21-bff7faf046ec",
      "name": "Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        800,
        0
      ],
      "parameters": {
        "columns": {
          "value": {},
          "schema": [
            {
              "id": "searchOrganic",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "searchOrganic",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "pagesPerVisit",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "pagesPerVisit",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "target",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "target",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "visits",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "visits",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "users",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "users",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "timeOnSite",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "timeOnSite",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "bounceRate",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "bounceRate",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "displayDate",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "displayDate",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "autoMapInputData",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "",
          "cachedResultName": "webtraffic"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "",
          "cachedResultUrl": "",
          "cachedResultName": "Seo n8n"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "2ec4b6b3-d8e0-4afd-8230-05604e85a258",
      "name": "Check webTraffic",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        300,
        0
      ],
      "parameters": {
        "url": "https://website-traffic-checker-semrush.p.rapidapi.com/website-traffic.php",
        "method": "POST",
        "options": {},
        "sendBody": true,
        "contentType": "multipart-form-data",
        "sendHeaders": true,
        "bodyParameters": {
          "parameters": [
            {
              "name": "website",
              "value": "={{ $json.website }}"
            }
          ]
        },
        "headerParameters": {
          "parameters": [
            {
              "name": "x-rapidapi-host",
              "value": "website-traffic-checker-semrush.p.rapidapi.com"
            },
            {
              "name": "x-rapidapi-key",
              "value": "your key"
            }
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "8369d678-4bc7-4161-9aaf-ff47b627323c",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -760,
        -180
      ],
      "parameters": {
        "width": 620,
        "height": 720,
        "content": "# SEO Website Traffic Checker\n\n## Flow Description:\nThis workflow collects website traffic data based on a submitted website URL and appends the data to a Google Sheet.\n\n---\n\n## Node-by-Node Explanation\n\n### 1. **On form submission**  \nCaptures the website URL submitted by the user through a form.\n\n### 2. **Check webTraffic**  \nSends a request to the Semrush API to gather website traffic data.\n\n### 3. **Re format output**  \nExtracts and reformats the relevant traffic data from the API response.\n\n### 4. **Google Sheets** \nAppends the formatted traffic data into a designated Google Sheets document.\n\n"
      },
      "typeVersion": 1
    },
    {
      "id": "7bc4099c-7247-4ea8-8ff4-9f394c8f69bc",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -60,
        -200
      ],
      "parameters": {
        "height": 380,
        "content": "### 1. **On form submission**  \nCaptures the website URL submitted by the user through a form.  \nTriggers the flow to start when the form is filled and submitted.\n"
      },
      "typeVersion": 1
    },
    {
      "id": "d06319d7-ffeb-451d-ae97-0ae32e8b379c",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        220,
        -200
      ],
      "parameters": {
        "height": 380,
        "content": "### 2. **Check webTraffic**  \nSends a request to the Semrush API to gather website traffic data.  \nUses the URL submitted by the user to fetch traffic statistics."
      },
      "typeVersion": 1
    },
    {
      "id": "8d668a57-48db-4aec-b233-534ffdd89c44",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        480,
        -200
      ],
      "parameters": {
        "height": 380,
        "content": "### 3. **Re format output**  \nExtracts and reformats the relevant traffic data from the API response.  \nCleans the raw data for easier processing and usage.\n"
      },
      "typeVersion": 1
    },
    {
      "id": "7602afe9-89cf-439d-9587-530f0a4aa7b1",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        740,
        -200
      ],
      "parameters": {
        "height": 380,
        "content": "### 4. **Google Sheets**  \nAppends the formatted traffic data into a designated Google Sheets document.  \nStores the data for later analysis and reporting."
      },
      "typeVersion": 1
    }
  ],
  "connections": {
    "Check webTraffic": {
      "main": [
        [
          {
            "node": "Re format output",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Re format output": {
      "main": [
        [
          {
            "node": "Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "On form submission": {
      "main": [
        [
          {
            "node": "Check webTraffic",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

This workflow uses the Website Traffic Checker Semrush API to analyze website traffic and performance. It collects data through a user-submitted website URL and stores the results in Google Sheets for easy access and reporting. Ideal for SEO analysis and data tracking.

Source: https://n8n.io/workflows/7459/ — original creator credit. Request a take-down →

More Data & Sheets workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

Data & Sheets

Overview 🌐

Form Trigger, HTTP Request, Google Sheets
Data & Sheets

Splitout Code. Uses splitOut, httpRequest, googleSheets, stickyNote. Event-driven trigger; 36 nodes.

HTTP Request, Google Sheets, Form Trigger +1
Data & Sheets

This n8n workflow is designed for Customer Success Managers (CSM), marketers, sales teams, and data administrators who need to automate the process of uploading and processing CSV data in HubSpot. It

HTTP Request, Google Sheets, Form Trigger +1
Data & Sheets

The SEO On Page API is a powerful tool for keyword research, competitor analysis, backlink insights, and overall SEO optimization. With multiple endpoints, you can instantly gather actionable SEO data

Form Trigger, HTTP Request, Google Sheets
Data & Sheets

Demonstration video

Form Trigger, HTTP Request, Google Sheets