Cloud Computing 7 min read

Deploy n8n to the Cloud for Free in 5 Minutes: A Step‑by‑Step Guide

This guide shows how to create a fully functional, self‑hosted n8n workflow automation instance at zero cost by combining Hugging Face Spaces for free Docker hosting with Supabase's free Postgres backend, covering account setup, environment configuration, deployment, and verification steps.

Full-Stack Cultivation Path
Full-Stack Cultivation Path
Full-Stack Cultivation Path
Deploy n8n to the Cloud for Free in 5 Minutes: A Step‑by‑Step Guide

Why this combination

n8n : Open‑source workflow engine with extensive node library and active community.

Hugging Face Spaces : Free Docker container environment that can host arbitrary web services, suitable for running n8n.

Supabase : Open‑source Firebase alternative providing a free Postgres database, authentication and storage, sufficient for n8n’s persistent workflow and credential storage.

Prerequisites

Supabase account: https://supabase.com/

Hugging Face account: https://huggingface.co/

1. Configure Supabase database

n8n requires a Postgres database to store workflows, execution logs and credentials.

Log in to Supabase, open the Dashboard, create a new project (or use an existing organization), and set a secure database password. Remember this password for later steps.

After the project is created, click Connect , then select Transaction pooler → View parameters to display the connection details.

Record the following parameters from the panel: DB_POSTGRESDB_PASSWORD: the password set in step 1. DB_POSTGRESDB_USER: the Supabase Transaction pooler user. N8N_ENCRYPTION_KEY: a custom encryption key you generate. GENERIC_TIMEZONE: e.g. Asia/Shanghai. DB_POSTGRESDB_HOST: the host value shown under Transaction pooler.

2. Deploy n8n on Hugging Face Spaces

Log in to Hugging Face and navigate to https://huggingface.co/spaces. Search for n8n baoyin2024 and open the first result.

Click the “More” button next to the avatar and choose Duplicate this Space .

In the duplication dialog, fill the following Space secrets and variables with the values collected from Supabase:

DB_POSTGRESDB_PASSWORD
DB_POSTGRESDB_USER
N8N_ENCRYPTION_KEY
GENERIC_TIMEZONE
DB_POSTGRESDB_HOST
N8N_EDITOR_BASE_URL

: https://{hf-username}-{space-name}.hf.space (replace with your Hugging Face username and space name). WEBHOOK_URL: same value as N8N_EDITOR_BASE_URL. N8N_HOST: the host part of N8N_EDITOR_BASE_URL.

Click Duplicate Space to create your own copy.

3. Start and verify the instance

Return to the newly created Space homepage and click the Logs tab. Look for a line containing “Editor is now accessible via:” – this indicates that n8n has successfully connected to Supabase and started.

Open a browser and navigate to the N8N_EDITOR_BASE_URL you configured. The n8n initial‑setup page should appear.

Create an administrator account to reach the n8n main UI and begin building workflows.

If the URL returns a 404, open the browser’s developer tools, locate the iframe element, copy its src attribute, and open that address to access the deployed n8n service.

Because the database is hosted on Supabase, all workflows, credentials and execution logs persist permanently, even if the Hugging Face Space restarts or goes to sleep.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

Dockerworkflow automationcloud deploymentSupabasen8nPostgresHugging Face Spaces
Full-Stack Cultivation Path
Written by

Full-Stack Cultivation Path

Focused on sharing practical tech content about TypeScript, Vue 3, front-end architecture, and source code analysis.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.