Skip to main content

Delay football goal alerts with API-Football, Google Sheets and Gmail

Workflow preview

Workflow preview
100%
Delay football goal alerts with API-Football, Google Sheets and Gmail preview
Open on n8n.io

1. Workflow Overview

Your streaming service is 45 seconds behind live. Your phone notifications aren't. This workflow fixes that. Real time alerts arrive before they happen on your screen. You're watching a corner kick...

Best for

  • Personal Productivity automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.stickynote, n8n-nodes-base.scheduletrigger, n8n-nodes-base.code, n8n-nodes-base.googlesheets, n8n-nodes-base.if, n8n-nodes-base.httprequest, n8n-nodes-base.wait, n8n-nodes-base.gmail

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Mychel Garzon.

Original n8n.io source

1.1 Workflow description

Title
Delay football goal alerts with API-Football, Google Sheets and Gmail
Workflow name
Delay football goal alerts with API-Football, Google Sheets and Gmail

Your streaming service is 45 seconds behind live. Your phone notifications aren't. This workflow fixes that.

Real-time alerts arrive before they happen on your screen. You're watching a corner kick, your phone buzzes with a goal notification, moment destroyed. This workflow monitors live match data, detects goals for your team, then holds the notification for however long your stream is lagging. Test your delay once, never get spoiled again.

How it actually works

The schedule runs every 10 minutes, but here's the thing: it doesn't just blindly hit the API 144 times a day (which would blow through the free tier in like 18 hours). There's a timing check that reads your match kickoff from a Google Sheet and does the math: if you're more than 2 hours before or after the match, it just skips the whole thing. Saves about 80-90% of your rate limit for when matches are actually live.

Once you're inside the match window, the API call happens, and the data splits into two parallel branches (this took me forever to get right, more on that in a second):

Branch 1 - Goal Detection: Parses the event feed, checks if any goals happened that aren't already in your "notified" log (stored in the Sheet as a comma-separated string—yeah, I know, but it works). If there are new goals, it logs them, waits for your delay (you set this once, like 45 seconds or whatever your service needs), then fires off an email via Gmail with the scorer, minute, score, opponent. Done.

Branch 2 - Auto Reset: Reads the match status from the same API response. If it says FT (full time) or any of the finished codes (AET, PEN, CANC, etc.), it flips your Active column to "No" in the Sheet. This stops the polling automatically so you're not burning API calls after the match ends.

Setup

  1. Make a Google Sheet with these columns: User Email, Team ID, Active, Delay Seconds, Streaming Service, Match Datetime, Last Notified Goals, Last Notification. Only the first six need data from you, the last two auto-populate.

  2. Get an API-Football account (free tier is 100 requests/day). Grab your API key and find your team's ID from their docs.

  3. Connect your Google Sheets OAuth in n8n (you'll use it in 3 different nodes) and your Gmail OAuth (1 node).

  4. Replace YOUR_SPREADSHEET_ID in all the Google Sheets nodes with your actual Sheet ID (it's in the URL). Paste your API key into the HTTP Request node's headers.

  5. Before a match: add the kickoff time in ISO format (2026-06-15T15:00:00Z), set your delay in seconds (test with 45-60 first), flip Active to "Yes". That's it.

Who this is for

Football fans who are tired of the phone-muting game. Expats watching via VPN who have weird delays. Anyone who wants a free alternative to those paid spoiler blocker apps (which are like $5/month for something you can self-host in 15 minutes).

What you need

  • API-Football (free or paid, depending on how many matches you watch)
  • Google account (Sheets + Gmail)
  • n8n instance (cloud or self-hosted, doesn't matter)

If you want to extend it

Multi-channel: Add Slack/WhatsApp nodes in parallel with Gmail so you get notifications everywhere.

More events: Tweak the goal detection code to also catch cards, subs, VAR decisions, it's all in the same API response.

Auto-delay detection: Right now you set the delay manually. You could build a lookup table that maps streaming services to known delays and auto-populate it.

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - README: Setup & Fixes

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 2 - Sticky Note - Section 1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 3 - Sticky Note - Section

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 4 - Sticky Note - Section 2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 5 - Sticky Note - Section 3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 6 - Schedule: Every 10 Minutes

Type / Role
n8n-nodes-base.scheduleTrigger - scheduleTrigger
Config choices
Version 1.2

Block 7 - Setup Validation

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 8 - Load User Preferences

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.5

Block 9 - Filter Active Users Only

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.1

Block 10 - Check Match Timing Window

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 11 - Should Poll API?

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.1

Block 12 - API-Football: Get Live Match

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 13 - Detect New Goals

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 14 - Filter Error Results

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.1

Block 15 - Update Notified Goals Log

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.5

Block 16 - Wait: User Streaming Delay

Type / Role
n8n-nodes-base.wait - wait
Config choices
Version 1.1

Block 17 - Gmail: Send Goal Alert

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.1

Block 18 - Check Match Status

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 19 - Is Match Finished?

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.1

Block 20 - Disable Active Status

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.5

3. Summary Table

Workflow Delay football goal alerts with API-Football, Google Sheets and Gmail
Complexity advanced
Nodes 20
Categories Personal Productivity
Author Mychel Garzon
Published 12 May 2026

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/15675/15675.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Delay football goal alerts with API-Football, Google Sheets and Gmail do?

Your streaming service is 45 seconds behind live. Your phone notifications aren't. This workflow fixes that. Real time alerts arrive before they happen on your screen. You're watching a corner kick...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Personal Productivity use case.