serverserv serverserv

Error alerts on Telegram: free n8n workflow template

By the serverserv team · 3 min read · Updated

Workflows fail quietly: an expired token, a changed API, a full disk. This two-node error workflow sends you a Telegram message the moment any workflow fails, with the workflow name, the node, the error and a link to the execution.

Download the template

Free download
2 nodes · tested on n8n 2.35 · MIT licence · no credentials included
Download JSON
When a workflow failsError TriggerSend alertTelegram
How the workflow is wired, from the trigger at the top.

How it works

  1. When a workflow fails is n8n's Error Trigger. It runs whenever a workflow that uses it as its error workflow fails in production.
  2. Send alert sends a short message to your Telegram chat with the details and a link straight to the failed execution.

Nodes used: Error Trigger, Telegram.

What you need

  • A Telegram bot token from @BotFather and your chat ID

Set it up

  1. Import the workflow, add your Telegram credential and put your chat ID in Send alert.
  2. Save and activate it.
  3. Open each workflow you want covered, go to its Settings and choose this workflow as the Error workflow.

New to importing? In n8n, open a new workflow, then either paste the copied JSON onto the canvas or use the menu (the three dots) and choose Import from file. Credentials are never included, so you connect your own accounts after importing.

Ways to customise it

  • Send to Slack, Discord or email instead, or to several at once.
  • Add an IF node that only alerts for workflows tagged production.
  • Log every failure to a Google Sheet to spot the workflows that break most often.

Security notes

Error messages can include data from the failed run. The template trims the error to 500 characters; keep the chat private and do not send alerts to public channels.

Where to run it

Templates with webhooks or triggers need n8n running all the time and reachable over HTTPS. You can run n8n on your own computer to try it, but for real use it belongs on a server. serverserv n8n Hosting gives you n8n pre-installed on your own KVM server with HTTPS, from $14.99 a month with no execution limits, and we will set up your first workflow for you, this one included.

Questions

Why did I not get an alert when I tested in the editor?

Error workflows only run for production executions, not manual test runs. Activate a workflow, make it fail and the alert will arrive.

Do I need one error workflow per workflow?

No. One error workflow can cover all of them. Set it in each workflow's settings.

Is this n8n template free to use?

Yes. It is free under the MIT licence, for personal and business use. You need your own n8n instance and your own accounts for the connected apps.

Sources

Plans from $3.99/moSee plans