Comprehensive data conversion node for n8n - Handle Base64, Binary, Format conversions (JSON/XML/YAML/CSV), HTML generation, and various encodings
npm install n8n-nodes-data-converterA comprehensive data conversion node for n8n that handles Base64, Binary, Format conversions (JSON/XML/YAML/CSV), HTML generation, and various encodings - all in one place.
Stop writing Code nodes for common data transformations! This node provides a single, intuitive interface for all your data conversion needs:
- ✅ Base64 Operations - Encode/decode text, binary, JSON, and data URLs
- ✅ Binary Handling - Convert between JSON, text, and binary formats
- ✅ Format Conversions - Transform between JSON, XML, YAML, CSV, and Markdown
- ✅ HTML Generation - Create tables, lists, and formatted HTML from data
- ✅ Text Encoding - URL, HTML entity, and hex encoding/decoding
- ✅ String Transformations - Filename cleaning, case conversions, slugification, and text manipulation
1. In n8n, go to Settings > Community Nodes
2. Search for n8n-nodes-data-converter
3. Click Install
``bash`
npm install n8n-nodes-data-converter
Then restart your n8n instance.
Convert JSON data to Base64 for API calls:
``
Resource: Base64
Operation: JSON to Base64
Transform JSON configuration to YAML format:
``
Resource: Format
Operation: JSON to YAML
Create an HTML table from JSON data:
``
Resource: HTML
Operation: JSON to HTML Table
Clean and format filenames in one step:
``
Resource: String
Operation: Apply Multiple Operations
Operations:
1. Remove Special Characters (Keep Filename Characters: ON)
2. Convert to kebab-case
3. Convert to lowercase
Input: "My File (2024) - FINAL VERSION.pdf""my-file-2024-final-version.pdf"
Output:
| Operation | Description | Input | Output |
|-----------|-------------|-------|--------|
| Text to Base64 | Encode plain text | String | Base64 string |
| Base64 to Text | Decode Base64 to text | Base64 string | Plain text |
| Binary to Base64 | Encode binary data | Binary | Base64 string |
| Base64 to Binary | Decode to binary | Base64 string | Binary data |
| JSON to Base64 | Encode JSON object | JSON | Base64 string |
| Base64 to JSON | Decode to JSON | Base64 string | JSON object |
| Create Data URL | Create data URL with MIME type | Binary/Text | Data URL |
| Parse Data URL | Extract data from data URL | Data URL | Binary + metadata |
| Operation | Description | Input | Output |
|-----------|-------------|-------|--------|
| JSON to Binary | Convert JSON to binary | JSON | Binary buffer |
| Binary to JSON | Parse binary as JSON | Binary | JSON object |
| Text to Binary | Convert text to binary | String | Binary buffer |
| Binary to Text | Convert binary to text | Binary | String |
| Operation | Description | Input | Output |
|-----------|-------------|-------|--------|
| JSON to XML | Convert JSON to XML | JSON | XML string |
| XML to JSON | Parse XML to JSON | XML string | JSON object |
| JSON to YAML | Convert JSON to YAML | JSON | YAML string |
| YAML to JSON | Parse YAML to JSON | YAML string | JSON object |
| JSON to CSV | Convert JSON array to CSV | JSON array | CSV string |
| CSV to JSON | Parse CSV to JSON | CSV string | JSON array |
| JSON to Markdown | Format JSON as Markdown | JSON | Markdown string |
| JSON to String | Extract/format JSON content | JSON | String/HTML |
| CSV to Markdown | Convert CSV to Markdown table | CSV string | Markdown table |
| Operation | Description | Input | Output |
|-----------|-------------|-------|--------|
| JSON to HTML Table | Create HTML table | JSON array | HTML table |
| JSON to HTML List | Create HTML list | JSON array | HTML ul/ol |
| CSV to HTML Table | Convert CSV to table | CSV string | HTML table |
| Markdown to HTML | Convert Markdown to HTML | Markdown | HTML string |
| HTML to Markdown | Convert HTML to Markdown | HTML | Markdown string |
| Operation | Description | Input | Output |
|-----------|-------------|-------|--------|
| URL Encode | Encode for URLs | String | URL-encoded string |
| URL Decode | Decode from URLs | URL-encoded | Plain string |
| HTML Entity Encode | Encode HTML entities | String | HTML-safe string |
| HTML Entity Decode | Decode HTML entities | HTML string | Plain string |
| Hex Encode | Convert to hexadecimal | String/Binary | Hex string |
| Hex Decode | Convert from hexadecimal | Hex string | String/Binary |
| Operation | Description | Input | Output |
|-----------|-------------|-------|--------|
| Apply Multiple Operations | Chain multiple string operations in sequence | String | Transformed string |
| Clean Filename | Remove unsafe characters from filenames | String | Safe filename |
| Slugify | Create URL-friendly slug | String | Slug string |
| Title Case | Convert to Title Case | String | Title Case String |
| Camel Case | Convert to camelCase | String | camelCase string |
| Kebab Case | Convert to kebab-case | String | kebab-case string |
| Snake Case | Convert to snake_case | String | snake_case string |
| Upper Case | Convert to UPPERCASE | String | UPPERCASE STRING |
| Lower Case | Convert to lowercase | String | lowercase string |
| Normalize Whitespace | Clean up extra spaces | String | Normalized string |
| Parse Email Address | Extract name, email, domain from email strings | String | Object with parts |
| Remove Special Chars | Keep only letters/numbers (with options) | String | Clean string |
| Capitalize First | Capitalize first letter | String | Capitalized string |
| Reverse Text | Reverse character order | String | Reversed string |
| Truncate | Shorten text with suffix | String | Truncated... |
| Pad Text | Add padding characters | String | Padded string |
#### Apply Multiple Operations
The Apply Multiple Operations feature allows you to chain multiple string transformations in a single operation:
- Sortable operations list - Drag and drop to reorder operations
- All operations supported - Combine any string operations
- Configurable options - Each operation can have its own settings
- Sequential processing - Operations are applied in the order specified
Example combinations:
- Remove Special Characters → Convert to snake_case
- Normalize Whitespace → Slugify → Truncate
- Clean Filename → Convert to kebab-case → Lower Case
#### JSON to String Operation
The JSON to String operation provides flexible ways to extract or format JSON content:
Extraction Modes:
- Pretty Print - Format JSON with customizable indentation
- Compact - Minified JSON without whitespace
- Extract Field - Extract specific field values using dot notation (e.g., data.items[0].name){{field}}
- Template - Format using templates with placeholders
Use Cases:
- Extract HTML content from JSON fields for direct rendering
- Generate HTML from JSON using templates
- Extract specific values from nested JSON structures
- Format JSON for display or API requirements
Template Example: {{description}}
`html`
{{title}}
Price: ${{price}}
#### Remove Special Characters Options
When using Remove Special Characters, you can configure:
- Keep File Extension - Preserves the file extension (last dot and everything after)
- Keep Filename Characters - Preserves dots (.), hyphens (-), and underscores (_) for filenames
- Keep Numbers - Whether to keep numeric characters
- Keep Spaces - Whether to preserve spaces
Webhook → Data Converter (Base64 to Binary) → Save to Storage
`$3
`
Database → Data Converter (JSON to XML) → SOAP API
`$3
`
Data → Data Converter (JSON to Markdown) → Email/Slack
`$3
`
Form Data → Data Converter (Base64 to Binary) → Cloud Storage
`$3
`
User Input → Data Converter (Clean Filename) → File System
`$3
`
Blog Title → Data Converter (Slugify) → URL Path
`🤖 AI Agent Compatibility
This node is fully compatible with AI agents (
usableAsTool: true). All operations include:
- Clear descriptions
- Example inputs/outputs
- Structured error messages
- Predictable behavior⚙️ Advanced Options
$3
- All operations support continueOnFail`"Invalid Base64 string"
- Ensure the input is properly Base64 encoded
- Check for spaces or special characters
"Cannot parse JSON"
- Validate JSON syntax
- Check for trailing commas or unquoted keys
"CSV parsing failed"
- Verify delimiter settings
- Check for inconsistent column counts
See CHANGELOG.md for full version history.
Contributions are welcome! Please:
1. Fork the repository
2. Create a feature branch
3. Commit your changes
4. Push to the branch
5. Open a Pull Request
MIT - See LICENSE file
Created by Jez (Jeremy Dawes)
- GitHub Repository
- npm Package
- n8n Community
---
Need help? Open an issue on GitHub or reach out in the n8n community forum!