TD;LR
n8n is an open-source workflow automation tool that allows you to automate tasks and integrate different applications. It provides a visual interface to create workflows, making it easy to connect various services and automate repetitive tasks. n8n can be self-hosted or run in the cloud, and it supports a wide range of integrations with popular applications and services.
Install Self-hosted n8n on MacBook Pro
Premise
The following components are already installed on the Mac
macOS Ventura
├── Colima
├── Docker CLI
└── Docker Compose
Components to install
The only additional component we need is n8n that is not installed directly on macOS but rather in a container. We will use Docker Compose to manage the n8n container.
The architecture looks like this:
macOS
└── Colima Linux VM
└── Docker Engine
└── n8n Container
Final Diectory Structure
After the installation, the project directory will look like this:
~/Dev/projects/n8n/
├── compose.yaml
└── data/
├── config
├── database.sqlite
├── binaryData/
├── git/
├── nodes/
└── ssh/
Installation Steps
-
Create compose.yaml
services: n8n: image: docker.n8n.io/n8nio/n8n:latest container_name: n8n restart: unless-stopped ports: - "127.0.0.1:5678:5678" environment: TZ: Asia/Tokyo GENERIC_TIMEZONE: Asia/Tokyo N8N_SECURE_COOKIE: "false" volumes: - ./data:/home/node/.n8n -
Validate the Compose File Before downloading anythin, let Docker validate the syntax.
% docker compose config docker: unknown command: docker compose Run 'docker --help' for more information -
Use
docker-composeinstead ofdocker compose.% brew install docker-compose -
Validate the Compose File again
% docker-compose config name: n8n services: n8n: container_name: n8n environment: GENERIC_TIMEZONE: Asia/Tokyo N8N_SECURE_COOKIE: "false" TZ: Asia/Tokyo image: docker.n8n.io/n8nio/n8n:latest networks: default: null ports: - mode: ingress host_ip: 127.0.0.1 target: 5678 published: "5678" protocol: tcp restart: unless-stopped volumes: - type: bind source: /Volumes/ST500LT/gxliu/Dev/projects/n8n/data target: /home/node/.n8n bind: {} networks: default: name: n8n_default
The normalized configuration is printed, so the file is valid.
-
Download the n8n image
% docker-compose pull [+] pull 13/13 ✔ Image docker.n8n.io/n8nio/n8n:latest Pulled -
Start the n8n container
% docker-compose up -d [+] up 2/2 ✔ Network n8n_default Created 0.3s ✔ Container n8n Started -
Check all running containers:
% docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES e41109399fbe docker.n8n.io/n8nio/n8n:latest "tini -- /docker-ent…" 3 minutes ago Up 3 minutes 127.0.0.1:5678->5678/tcp n8n -
Check the startup logs
% docker logs n8n n8n | No encryption key found - Auto-generating and saving to: /home/node/.n8n/config n8n | Initializing n8n process n8n | n8n ready on ::, port 5678 n8n | Migrations in progress, please do NOT stop the process. n8n | Starting migration InitialMigration1588102412422 n8n | Finished migration InitialMigration1588102412422 n8n | Starting migration WebhookModel1592445003908 ...omitted... n8n | Building workflow dependency index... n8n | Finished building workflow dependency index. Processed 0 draft workflows, 0 published workflows. n8n | n8n | Editor is now accessible via: n8n | http://localhost:5678 -
Open n8n
Open this URL in your browser:http://localhost:5678/setup
This is the owner-account creation page.
Create an Automation Workflow
Preperation
- Create a new owner account
-
Get a free license key

- The license key will be sent to your email address.
The basic lifecycle
Trigger
│
▼
Read Input
│
▼
Process Data
│
▼
Decision (optional)
│
▼
Call APIs / AI / Database
│
▼
Send Output
Example 1: Hello World
-
Workflow
Manual Trigger │ ▼ Edit Fields (Set) │ ▼ Code

- Click the “Execute Workflow” button to execute the workflow.

- Click the “Edit Fields” node to see the execution result.

Example 2 – Calling a REST API
-
Workflow
When clicking "Execute workflow" │ ▼ HTTP Request -
Add an HTTP Request Node
Click the + button and search for “HTTP Request”. Then click the “HTTP Request” node to add it to the workflow. - Configure the Node
- Set the HTTP Method to “GET”
- Set the URL to “https://api.github.com/users/octocat”
- Click “Execute Node” to test the request.
No authentication is required because GitHub allows this endpoint to be accessed anonymously.
-
Execute
Click the “Execute Workflow” button to run the workflow. The HTTP Request node will fetch data from the GitHub API and display the response. -
View the Result
Click the “HTTP Request” node to see the execution result. You should see a JSON response containing information about the GitHub user “octocat”.Example JSON Response
```json [ { "login": "octocat", "id": 583231, "node_id": "MDQ6VXNlcjU4MzIzMQ==", "avatar_url": "https://avatars.githubusercontent.com/u/583231?v=4", "gravatar_id": "", "url": "https://api.github.com/users/octocat", "html_url": "https://github.com/octocat", "followers_url": "https://api.github.com/users/octocat/followers", "following_url": "https://api.github.com/users/octocat/following{/other_user}", "gists_url": "https://api.github.com/users/octocat/gists{/gist_id}", "starred_url": "https://api.github.com/users/octocat/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/octocat/subscriptions", "organizations_url": "https://api.github.com/users/octocat/orgs", "repos_url": "https://api.github.com/users/octocat/repos", "events_url": "https://api.github.com/users/octocat/events{/privacy}", "received_events_url": "https://api.github.com/users/octocat/received_events", "type": "User", "user_view_type": "public", "site_admin": false, "name": "The Octocat", "company": "@github", "blog": "https://github.blog", "location": "San Francisco", "email": null, "hireable": null, "bio": null, "twitter_username": null, "public_repos": 8, "public_gists": 8, "followers": 23295, "following": 9, "created_at": "2011-01-25T18:44:36Z", "updated_at": "2026-06-22T11:32:20Z" } ] ```
Example 3 – GitHub REST API with Authentication
-
Workflow
GitHub Personal Access Token │ ▼ GitHub REST API │ ▼ Repository JSON │ ▼ Extract only: - name - language - stars - Create a GitHub Personal Access Token
- Go to GitHub Settings > Developer settings > Personal access tokens
- Choose “Fine-grained personal access tokens”
- Clidk “Generate new token”
- Repository access “Public repositories (Read-only)”
- Create an HTTP Request Node
- HTTP Method : “GET”
- URL : “https://api.github.com/user/repos”
- Authentication : “Generic Credential Type”
- Generic Auth Type : “Bearer Auth”
-
Execute
In the “HTTP Request” node, click “Execute setup” to test the request. You should see a JSON response containing the repositories of the authenticated user. -
Add Edit Fields
AddEdit Fieldsnode after the HTTP Request node. -
Extract Only Three Fields– |field name|value| |:-|:-| |repository|| |language|| |stars||
-
Execute the Workflow
Click the “Execute Workflow” button to run the workflow. The HTTP Request node will fetch data from the GitHub API, and the Edit Fields node will extract only the specified fields.
Conclusion
In this guide, we have successfully installed n8n on a MacBook Pro using Docker Compose and created a few example workflows to demonstrate its capabilities. n8n provides a powerful and flexible platform for automating tasks and integrating various services, making it a valuable tool for developers and businesses alike.