Skip to content
BotServBotServ
n8nWorkflow TemplatesTemplatesEmailRSSSocial Media

n8n Workflow Templates

n8n workflow templates for AI automation. Ready-to-use workflows for email, documents, RSS, social media and more.

S

schutzgeist

5 min read
n8n Workflow Templates

n8n Workflow Templates

What this article covers

  • Ready-made workflows to get you started quickly.
  • Templates for email automation, document processing, and monitoring.
  • AI workflows with Ollama as finished templates.
  • How to import, customize, and extend templates.
  • Creating and sharing your own templates.

Introduction: n8n workflow templates explained

Instead of building every workflow from scratch, you use ready-made templates. n8n has a large template library, and you can export and share your own workflows as JSON. Templates save time and demonstrate best practices.

This article is aimed at users who want to set up productive workflows quickly. For fundamentals, see n8n installation and n8n guide.

Why use workflow templates?

Imagine you want to automatically classify emails. Instead of figuring out which nodes you need, you import a finished template and adapt it. Your workflow runs in 10 minutes instead of 2 hours.

n8n workflow templates in brief

Workflow templates are finished n8n workflows stored as JSON. You import them, configure credentials and parameters, and the workflow runs. n8n has over 1,000 official templates, plus community templates.

The core idea is simple: don’t reinvent, just adapt.

Who should read this article?

  • n8n beginners who want to get started quickly.
  • Automation enthusiasts looking for best practices.
  • Teams that want to standardize workflows.
  • Self-hosters building their own template library.

Importing templates

From the n8n template library

  1. Click β€œTemplates” in n8n.
  2. Search for a template (e.g., β€œOllama” or β€œEmail”).
  3. Click β€œUse Workflow”.
  4. Configure credentials.
  5. Activate the workflow.

Importing JSON

# Export workflow
# In n8n: Workflow β†’ Download

# Import workflow
# In n8n: Workflows β†’ Import from File β†’ select JSON

Via API

curl -X POST http://localhost:5678/api/v1/workflows \
  -H "X-N8N-API-KEY: your-api-key" \
  -H "Content-Type: application/json" \
  -d @workflow.json

Template 1: Email classification with Ollama

{
  "name": "Classify emails with Ollama",
  "nodes": [
    {
      "type": "n8n-nodes-base.imap",
      "name": "Email Trigger",
      "parameters": {
        "mailbox": "INBOX"
      }
    },
    {
      "type": "n8n-nodes-base.httpRequest",
      "name": "Ollama Classification",
      "parameters": {
        "method": "POST",
        "url": "http://ollama:11434/api/chat",
        "body": {
          "model": "llama3.1",
          "messages": [
            {
              "role": "system",
              "content": "Classify the email into: support, sales, billing, spam, other. Reply with only the category."
            },
            {
              "role": "user",
              "content": "Subject: {{$json.subject}}\nContent: {{$json.body}}"
            }
          ],
          "stream": false
        }
      }
    },
    {
      "type": "n8n-nodes-base.switch",
      "name": "Category Routing",
      "parameters": {
        "rules": [
          { "value": "support", "output": "support" },
          { "value": "sales", "output": "sales" },
          { "value": "spam", "output": "spam" }
        ]
      }
    }
  ]
}

See email automation for details.

Template 2: Daily report with AI

Workflow: Daily AI report

1. Schedule Trigger: Daily at 7:00 AM
2. HTTP Request: Fetch metrics from Prometheus
3. HTTP Request: Fetch logs from the last 24 hours
4. Ollama: Generate report
   Prompt: "Create a daily status report
            based on the metrics and logs."
5. Email: Send report to admin

Template 3: RSS β†’ Summary β†’ Mastodon

Workflow: RSS to social media

1. RSS Trigger: New blog article
2. Ollama: Summarize in 280 characters
3. HTTP Request: Post to Mastodon
   Body: "{{summary}} #blog #ai"

Template 4: Upload document β†’ Index

Workflow: Index document in RAG

1. Webhook: File upload
2. Function: Extract text (PDF)
3. Function: Chunking (500 characters)
4. Ollama: Embeddings (nomic-embed-text)
5. HTTP Request: Store in Qdrant
6. Response: "Document indexed"

See RAG workflows.

Template 5: Webhook β†’ AI response β†’ Slack

Workflow: Slack bot with Ollama

1. Webhook: Slack slash command
2. Ollama: Generate response
3. HTTP Request: Post response to Slack

Template 6: Backup reminder

Workflow: Weekly backup reminder

1. Schedule Trigger: Friday at 4:00 PM
2. SSH Node: Check backup status
3. Ollama: Create status report
4. Email: Send report
   On error: Alert admin

Creating your own templates

Best practices

// 1. Extract parameters
// Instead of hardcoded values: use credentials and environment variables
const apiUrl = $env.OLLAMA_URL || "http://ollama:11434";

// 2. Add error handling
try {
  const result = await callApi();
  return { success: true, data: result };
} catch (e) {
  return { success: false, error: e.message };
}

// 3. Add descriptions
// Each node should have a meaningful name

// 4. Use sticky notes for documentation
// Use sticky notes to explain the workflow

Exporting templates

# In n8n: Workflow β†’ Menu β†’ Download
# Creates: workflow.json

# Share:
# - Store in a Git repository
# - Upload to n8n Community
# - Send via email to colleagues

Building a template library

templates/
β”œβ”€β”€ email/
β”‚   β”œβ”€β”€ classification.json
β”‚   β”œβ”€β”€ auto-reply.json
β”‚   └── newsletter.json
β”œβ”€β”€ documents/
β”‚   β”œβ”€β”€ pdf-summarize.json
β”‚   β”œβ”€β”€ rag-indexing.json
β”‚   └── ocr-pipeline.json
β”œβ”€β”€ monitoring/
β”‚   β”œβ”€β”€ daily-report.json
β”‚   └── alert-analysis.json
└── social-media/
    β”œβ”€β”€ rss-to-mastodon.json
    └── article-to-linkedin.json

Security considerations

  • Never include credentials in templates: API keys and passwords belong in credentials, not in the workflow JSON.
  • Review templates: Community templates can contain poor or unsafe practices. Review before importing.
  • Internal URLs: Replace internal URLs with environment variables.
  • Minimal permissions: Templates should use only necessary permissions. See tool permissions.

Common pitfalls

  • Forgotten credentials: Templates without credentials won’t work. Set them up.
  • Incorrect URLs: localhost in Docker refers to the container itself. Use http://ollama:11434 instead.
  • Outdated templates: n8n changes over time. Old templates may contain deprecated nodes.
  • No testing: Don’t import blindly. Test with sample data.
  • Overly complex templates: Large templates are hard to customize. Break them down.

Further reading

Key takeaways:

  • Templates are ready-made workflows as JSON, import them, customize them, done.
  • n8n has over 1,000 official templates, plus community options.
  • Important templates: email classification, reports, RSS, RAG indexing.
  • Creating your own templates: extract parameters, document, and share.
  • Keep credentials separate, never include them in templates.

FAQ

Where do I find n8n templates?

In n8n under Templates (over 1,000 templates), in the n8n Community, and on GitHub. You can also export your own templates as JSON and share them.

How do I import a template?

Workflows β†’ Import from File β†’ select JSON. Or directly from the template library with Use Workflow. Then configure your credentials.

How do I create my own template?

Build the workflow, export as JSON (Workflow β†’ Download). Remove credentials, document with sticky notes, and share the file.

Are credentials included in templates?

No, credentials are not exported. This is good for security, but it means you need to reconfigure all credentials after importing.

Are there templates for Ollama?

Yes, the template library includes Ollama workflows for classification, summarization, RAG, and more. Search for Ollama or LLM.

How do I customize templates?

Import the template, change URLs (e.g., http://ollama:11434), configure credentials, and modify prompts and parameters as needed.

Can I version templates?

Yes, store workflow JSONs in a Git repository. This gives you version history, lets you track changes, and makes it easy to share templates with your team.

Are community templates secure?

Not automatically. Review community templates before importing: What nodes are used? Do they send data to external APIs? Are permissions minimal?

Sources and further reading

Back to Blog
Share:

Related Posts