npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

n8n-nodes-datatable-variables

v1.1.0

Published

n8n community node for local datatable variables storage

Downloads

342

Readme

n8n-nodes-datatable-variables

This is an n8n community node package that enables users to create local tables and store variables within them. It runs entirely locally on your host or container, without requiring any external database servers or cloud service setups.

With this node, you can easily cache, share, and persist variables between workflow runs, execution iterations, or different paths in a workflow.


Key Features

  • Local Storage: Persists data inside ~/.n8n/n8n-nodes-datatable-variables.json.
  • Concurrency & Thread Safety: Uses a self-healing .lock file (with PID tracking and a 5-second automatic expiration timeout) and atomic file writes (via temporary file swap) to ensure data safety when multiple executions modify tables simultaneously.
  • Rich Data Types Support: Supports Text, Numbers, Booleans, Dates, parsed JSON objects, and Binary files.
  • Change Log Polling Trigger: A trigger node that watches for table updates and fires workflows based on changes (for all variables, a specific key, or multiple keys).
  • Import/Export: Easily backup or restore tables as binary JSON files or raw JSON objects.

Directory Structure

n8n-nodes-datatable-variables/
├── icons/
│   ├── datatable.svg                  # Icon for the main node
│   ├── datatable-trigger.svg          # Icon for the trigger node
│   └── datatable-import-export.svg    # Icon for the import/export node
├── nodes/
│   └── DatatableVariables/
│       ├── db.ts                      # Local database driver (locks, writes, changes)
│       ├── DatatableVariables.node.ts # Main node logic (CRUD operations)
│       ├── DatatableVariablesTrigger.node.ts # Polling trigger node
│       └── DatatableVariablesImportExport.node.ts # Data backup and restore node
├── package.json                       # Package configurations and scripts
└── tsconfig.json                      # TypeScript configuration

Available Nodes & Operations

1. Datatable Variables (Main Node)

Acts as a local key-value datatable store.

Resource: Variable

  • Set: Save or update a variable.
    • Supports inline table creation if the table doesn't exist yet via [+ Create New Table...].
    • Type-safe inputs: Text, Number, Boolean, JSON, Date, and Binary files (binary files are read from the incoming item and stored inside the database as Base64 strings along with filename and mimeType).
  • Get: Load a variable from a table.
    • If it is a binary file, it will reconstruct the file buffer and output it as a binary property on the n8n execution item.
  • Delete: Delete a variable key from a table.
  • Get All: Retrieve all variables in a table as a key-value object (binary files return file metadata).

Resource: Table

  • List: List all tables in your local database along with their variable count.
  • Delete: Delete a table and all variables within it.

2. Datatable Variables Trigger

Polls the local database change-log and triggers workflows when updates occur.

  • Table Name: Choose which table to watch.
  • Trigger On:
    • All Changes in the Table: Fires on any variable insert, update, or deletion.
    • Specific Variable: Fires only when a specific key is updated.
    • Multiple Variables: Fires when any key in a defined list is updated.
  • State Tracking: Uses n8n workflow static data (node scope) to track the processed change IDs. It automatically initializes to the latest change ID when activated, ensuring that workflows only fire on new changes.

3. Datatable Variables Import/Export

Lets you download or restore your datatable variables easily.

  • Export: Export a single table or all tables. Output format can be:
    • JSON File (Binary): Generates a downloadable .json file.
    • JSON Output: Outputs the raw JSON structure directly on the execution node.
  • Import: Reads a backup file or a raw JSON string.
    • Modes: Choose Merge (insert/overwrite keys) or Replace (wipes the database first and loads the new content).

Installation

Community Node Install (Standard)

Refer to the official n8n Community Nodes Installation Guide to install this package in your n8n instance using:

n8n-nodes-datatable-variables

Local Development Setup

To link and run this node locally for testing:

  1. Build & Link the Node:

    cd /path/to/n8n-nodes-datatable-variables
    npm install
    npm run build
    npm link
  2. Mount in your local n8n installation: Navigate to your local n8n folder (usually ~/.n8n/):

    cd ~/.n8n
    mkdir nodes
    cd nodes
    npm link n8n-nodes-datatable-variables
  3. Restart n8n: Restart your n8n server, and the new nodes will appear in your workflow editor.


License

MIT