Telegram User Registration and Google Sheets CRM - n8n Workflow

Automate user registration for Telegram groups or bots. This n8n workflow uses Google Sheets as a database to check for existing users and send personalized welcome messages using the Telegram n8n node.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

Bot developers needing reliable user persistence without a dedicated SQL database.
Community managers automating Telegram onboarding processes.
Users looking for practical n8n templates integrating messaging apps and data storage.
Automation specialists seeking core logic examples using the If n8n node and Google Sheets integration.

Overview

This highly functional n8n workflow solves the problem of tracking and managing Telegram user interactions effectively. By leveraging Google Sheets, the automation provides a simple yet scalable Customer Relationship Management (CRM) backbone. When a Telegram user interacts, the process is initiated by an n8n trigger. The system immediately checks if they are a new registrant or a returning member using the Google Sheets n8n node. This streamlined process ensures that every user receives an appropriate, personalized welcome message via Telegram, making this one of the most valuable n8n templates for engagement and community growth. Understanding this n8n workflow offers great insight into complex branching logic.

How it Works

This comprehensive n8n workflow manages user state and communication:


  1. Initiation (n8n Trigger): The Trigger Start n8n node initiates the flow, typically acting as a webhook receiving data directly from Telegram when a specific event occurs.

  2. Data Preparation: The Trigger_Data n8n node (a Set node) structures and extracts essential user information (like chat ID and username) from the incoming webhook payload.

  3. User Lookup: The Find User n8n node queries the configured Google Sheets spreadsheet. It searches the sheet using the unique user identifier to check for prior registration.

  4. Data Consolidation: The Data to Save n8n node formats both the incoming Telegram data and the results of the Google Sheets lookup for downstream use.

  5. Decision Point: The crucial New? n8n node (an If node) evaluates whether a matching user record was found. This determines the subsequent path of the n8n workflow.

  6. New User Path (True): If the user is new, the Write to Data Base n8n node appends a new record to Google Sheets, completing the registration. A comprehensive Welcome message is then sent via the Telegram n8n node.

  7. Returning User Path (False): If the user is found, the Update status n8n node updates their existing row in Google Sheets (e.g., updating the 'Last Seen' timestamp). A personalized Welcome back message is immediately sent using the Telegram n8n node, demonstrating effective user engagement.

Installation Guide

To deploy this powerful n8n workflow template, follow these steps:


  1. Import: Copy the provided JSON data and paste it into your n8n instance using the 'New' menu -> 'Import from JSON'.

  2. Google Sheets Setup: You need a Google Sheets database set up with columns to store user information (ID, Username, Registration Date, Status, etc.).

  3. Credential Setup: Create and configure credentials for the following n8n node services:

Google Sheets: Authenticate your Google Sheets account and ensure the credentials have read/write access to the designated spreadsheet. You must specify the Spreadsheet ID in the Find User, Write to Data Base, and Update status nodes.
Telegram: Authenticate your Telegram bot token. Configure the Welcome message and Welcome back n8n nodes to use your Chat ID or Bot settings.

  1. Trigger Configuration: Ensure the Trigger Start n8n trigger is correctly receiving data from your external source (e.g., your Telegram bot webhook setup).

  2. Activation: Save the n8n workflow and activate it.

Node Details

Trigger Start (n8n trigger): The entry point of the n8n workflow, executed by an external signal (like a webhook from a Telegram bot).
Trigger_Data & Data to Save (Set n8n node): Used to define and format variables. They ensure the user ID and other critical data points are correctly structured before querying the database.
Find User (Google Sheets n8n node): Function: Queries the Google Sheet using the 'Get All' operation, typically filtering by user ID to check for existing records. This is critical for the flow control.
New? (If n8n node): Function: The core flow control mechanism. It checks if the data returned by 'Find User' is empty (New User) or contains data (Existing User).
Write to Data Base (Google Sheets n8n node): Function: Executes the 'Append' operation to register a new user row when the 'New?' n8n node returns True.
Update status (Google Sheets n8n node): Function: Executes the 'Update' operation, ensuring that the status or last interaction time of a returning user is correctly logged.


  • Welcome message & Welcome back (Telegram n8n node): Function: Sends personalized responses to the user. This is configured to use the user's Chat ID extracted earlier in the n8n workflow.

Related n8n Workflows

Paid

Nodes: 6 Nodes
Updated: December 26 2025
View all
Created by

Automation & AI expert with over 7 years of experience in the digital & tech industry. Founder digital design, web & mobile development studio INSAIM.DESIGN. Focusing on startups & tech companies and helping to streamline their processes with AI and automation.

Featured*