Imagine a lead fills a form on your website. Within seconds, their details are saved in Google Sheets, they get a WhatsApp reply, your sales person gets a notification, and an AI checks whether the lead looks serious. Nobody touched a keyboard. That is an automation — and n8n is one of the most popular tools for building them.
What is n8n?
n8n (pronounced "n-eight-n") is a workflow automation platform. You build workflows on a visual canvas by connecting boxes called nodes. Each node does one job: receive data, change it, send it to another app, or ask an AI model to think about it. n8n connects with hundreds of apps and can talk to almost any other service through its API.
It is popular with agencies and businesses because it handles complex logic, can be self-hosted on your own server, and has built-in nodes for AI models and AI agents.
Four ideas you need to understand
1. Triggers
A trigger starts the workflow. It can be a form submission, a new row in a sheet, a schedule ("every day at 9 AM"), an incoming email or a webhook — a special URL that another app calls when something happens.
2. Nodes
After the trigger, each node takes the data, does something with it and passes it on: Google Sheets, Gmail, Slack, HTTP Request, an AI model, an IF condition and so on.
3. Data (JSON)
Data moves between nodes as JSON — simple labelled fields like "name": "Rahul" and "phone": "98xxxxxx10". Once you can read JSON, you can map any field from one app into another.
4. Credentials
To use Gmail or Google Sheets, n8n needs permission. You add credentials once and reuse them in any workflow. Keep them private — they are keys to your accounts.
Build your first workflow: website lead → Sheet → email alert
- Create a Webhook trigger. Add a Webhook node and copy its test URL. Set the method to POST.
- Send a test lead. Point your website form (or a tool like a form builder) to the webhook URL and submit a test entry. You will see the name and phone arrive as JSON.
- Clean the data. Add an Edit Fields (Set) node to keep only name, phone, course and page, and to format the phone number.
- Save it to Google Sheets. Add a Google Sheets node with "Append row" and map each field to a column.
- Send yourself an alert. Add a Gmail node that emails you "New lead: {{name}} – {{phone}}".
- Activate. Switch the webhook to its production URL, activate the workflow and test once more.
Tip: build one node at a time and click "Execute step" after each. You will see exactly what data comes out, which makes mistakes easy to spot.
Add AI to the workflow
Insert an AI node between the trigger and the sheet. Ask it to read the lead's message and return structured fields: intent (course enquiry, price only, spam), urgency and a suggested first reply. Use an IF node to send high-intent leads straight to WhatsApp or a call queue. This is the first step towards an AI agent.
Useful automations for local businesses
- Instant WhatsApp or email reply to every new enquiry.
- Daily summary of yesterday's leads and sales sent to the owner.
- Reminders before appointments or demo classes.
- Collecting Google reviews from happy customers after a purchase.
- Turning one blog post into draft social posts for review.
Common beginner mistakes
- Forgetting to switch from the test webhook URL to the production URL.
- Not handling errors — add an error workflow that alerts you when something fails.
- Letting AI send messages to customers without a review step at first.
- Building one giant workflow instead of small, testable pieces.
Learn n8n with real projects
At HSDM's AI Automation & AI Agents course in Hisar, you build these workflows for real business scenarios over 90 days — from lead systems to AI agents and AI voice calling agents — and learn how to sell them as a service.