Use this powerful n8n workflow to instantly convert Obsidian notes into professional emails via Gmail. Features attachment processing, YAML metadata parsing, and instant confirmation responses.
Download this n8n workflow template and start using it instantly.
This advanced n8n workflow solves the problem of seamlessly integrating a local knowledge management system (Obsidian) with a major email client (Gmail). By leveraging the Obsidian Post Webhook plugin, users can trigger the entire process directly from within their notes. The key value provided by this specific n8n workflow lies in its sophisticated handling of email metadata, which is extracted from YAML frontmatter, and its robust process for converting embedded attachments (like images) from base64 encoding into usable binary files for the Gmail n8n node. This ensures that whether you send a simple text email or a complex document with multiple attachments, the n8n automation handles the delivery flawlessly, providing instant feedback back to Obsidian.
This powerful n8n automation is initiated by a webhook call from Obsidian:
Webhook node, waiting for a POST request from the Obsidian Post Webhook plugin containing the note content, YAML metadata (recipient, subject), and base64-encoded attachments.If n8n node checks if the payload includes any attachments. This creates two distinct execution paths.If n8n node checks if the request is a simple plugin test. If it is a test, the n8n workflow immediately responds with 'Test successful'. If it's a real email, the process proceeds directly to the Email Without Attachments Gmail n8n node.Separate attachment data n8n node splits the incoming attachment array. A Set n8n node (Fix Base64 string) cleans up the base64 data by removing the MIME type prefix. The Convert Attachment to File n8n node converts this clean base64 string into binary data.Prepare Attachments for Email n8n node aggregates all processed binary files. The Email With Attachments Gmail n8n node then sends the complete email, dynamically populating fields like 'To', 'CC', 'BCC', and 'Subject' using expressions referencing the original webhook data.Date & Time n8n node captures the current timestamp. The Respond to Obsidian n8n node then sends a final confirmation back to the originating note in Obsidian, confirming the email was successfully sent along with the exact date and time.To deploy this useful n8n workflow, follow these steps:
Email With Attachments and Email Without Attachments Gmail n8n node instances.Webhook n8n trigger node. Activate the n8n workflow and copy the unique Test/Production Webhook URL. Webhook (n8n trigger): The entry point for the entire n8n workflow. It listens for a POST request from Obsidian, containing all the email data, including content and base64 attachments.
Check if attachments exist (If n8n node): Determines the flow path based on the presence of the body.attachments array in the incoming data. This is crucial for optimizing the n8n automation.
Separate attachment data (SplitOut n8n node): Essential for handling multiple attachments by splitting the array into individual items so that each can be processed separately by a subsequent n8n node.
Fix Base64 string (Set n8n node): Cleans the attachment data by using an expression to remove the unnecessary data:image/jpeg;base64, prefix, ensuring the Convert Attachment to File n8n node can correctly parse the payload.
Convert Attachment to File (Convert To File n8n node): This key n8n node converts the base64 string data property into binary data, which is required by the Gmail n8n node for sending actual attachments.
Prepare Attachments for Email (Aggregate n8n node): Collects all the individually converted binary items back together, aggregating them for efficient transmission in a single email.
Gmail (n8n node): Used twice (Email With Attachments and Email Without Attachments). It sends the email, dynamically mapping fields like recipient lists and subject using data extracted from the initial n8n trigger.
Respond to Obsidian (Respond to Webhook n8n node): Provides immediate feedback to the source application (Obsidian), confirming the completion of the n8n workflow execution.
Automate daily server health checks using this n8n workflow. Run SSH commands, check for upgradable packages, and send instant email notifications via SMTP if updates are detected.

Use this custom n8n workflow to schedule and automatically send a beautifully formatted daily weather report directly to your email using the OpenWeatherMap API and the Gmail n8n node.

Use this custom n8n workflow to fetch daily weather data from OpenWeatherMap, apply sophisticated processing logic using a Code n8n node, and send rich, HTML-formatted forecasts and recommendations directly to your Telegram chat. Start building with n8n templates today.

Use this advanced n8n workflow to send emails from custom Gmail aliases with optional attachments by directly interacting with the Gmail API. Essential for robust programmatic emailing.

Analyze Google Analytics data weekly using an n8n workflow. Extract page engagement, search console, and country data, utilize OpenRouter AI for SEO insights, and save reports to Baserow. Get started with n8n templates.

