Want to automate tasks? n8n is your answer! This guide shows you how to install n8n on your own computer, so you can test and build workflows without needing a server. Let’s get started!
Why Install n8n Locally?
- Free to Use: n8n’s community version is perfect for local projects.
- Learn and Test: Build and test workflows before deploying them.
- Privacy: Keep your data on your own machine.
- Automation: Automate repetitive tasks.
Choose Your Installation Method:
We’ll cover two easy ways to install n8n:
- Using npm (Node.js): Quick and simple for those comfortable with code.
- Using Docker: Easiest way to get started, even if you’re not a tech expert.
Method 1: Install n8n with npm (Node.js)
What you need: Node.js and npm (download from nodejs.org)
Steps:
- Install Node.js: Download and install from nodejs.org.
- Open your Terminal/Command Prompt.
- Type:
npm install n8n -g
(press Enter) - Type:
n8n
orn8n start
(press Enter) - Open your browser: Go to
http://localhost:5678
Method 2: Install n8n with Docker
What you need: Docker Desktop (download from docker.com)
Steps:
- Install Docker Desktop: Download and install from docker.com.
- Open your Terminal/Command Prompt.
- Type:
docker pull docker.n8n.io/n8nio/n8n
(press Enter) - Type:
docker run -it --rm --name n8n -p 5678:5678 -v ~/.n8n:/home/node/.n8n docker.n8n.io/n8nio/n8n
(press Enter) - Open your browser: Go to
http://localhost:5678
First Time Setup:
- Create your admin account (email, password).
- Explore the n8n interface (workflows, credentials).
Troubleshooting (Quick Tips):
- Can’t open
localhost:5678
? Make sure n8n is running. - npm errors? Double-check Node.js installation.
- Docker issues? Restart Docker Desktop.
Keep n8n Updated:
- npm:
npm update n8n -g
- Docker: Pull the latest image and restart the container.
Security (Even Locally):
- Use strong passwords.
- Back up your
~/.n8n
folder.
Conclusion:
You’ve now installed n8n! Start building your automation workflows.
One Response
I am a very Raw Newbie.
I installed n8n using (Node.js) on a local headless PC.
I tried to build my VERY simple first workflow and got stuck on the first step.
I have created a ssl certificate using cloudflare
I can open the workflow page from another PC on my LAN as well as from the outside world using the domain created for cloudflare SSL- no issues there
I started accessing n8n from a pc on my lan opening n8n workflow page using the local ip address:5678 – works fine
The trigger is a “On form Submission”
If I do a “Test workflow” I get a page:
“This site can’t be reached
localhost refused to connect.”
The parameters screen for the step indicate the flow is on
http:/localhost:5678
but it should be on http://192.168.1.40:5678
Digging in some documents, I found this:
https://docs.n8n.io/hosting/configuration/configuration-examples/webhook-url/?_gl=1*1lpxz94*_gcl_au*NzMxOTAyMjc1LjE3NDk0MDg0MjA.*_ga*MTMxMzg1ODYuMTc0OTQwODQxNw..*_ga_0SC4FF2FH9*czE3NDk0NDg3NzUkbzQkZzEkdDE3NDk0NDg4MTIkajIzJGwwJGgw
I have no isea where to put, save or run this command.
Any pointers please
Regards
Frits