Many web hosts run Node.js apps without giving you Docker or a command line: shared hosting such as Hostinger, cPanel and Plesk hosts with a "Node.js app" feature, and any server where you can run node. HAIMDALL comes as a ready-to-run folder for these hosts. There's nothing to install or build on the host.
Tip
On Hostinger, an AI assistant can do the whole installation for you. Connect Hostinger's MCP server to an assistant such as Claude, then give it the prompt in Setting up Hostinger with an AI assistant at the end of this article. The same prompt is in the package, as AI-SETUP-PROMPT-HOSTINGER.md.
If you have your own server with Docker, use Installing HAIMDALL instead: it includes the database and is the easiest to look after.
What you need
A host that runs Node.js 22 or later, and lets you set environment variables (most have a screen for them) or upload a
.envfile.A PostgreSQL database, version 14 or later. Many shared hosts only offer MySQL, which HAIMDALL doesn't use: a managed PostgreSQL service works with any host. Neon and Supabase both have free plans. Create a database there and copy its connection address (it starts
postgres://orpostgresql://). With Neon, use the direct address, not the "pooled" one.The HAIMDALL package for Node.js hosting:
haimdall-node-<version>.zip.Your HAIMDALL licence key, if you have one: without it, HAIMDALL runs as a 7-day free trial.
1. Choose a folder for HAIMDALL's files
HAIMDALL keeps uploaded images and attachments, and the interface text, in a data folder. By default it's the data folder inside the app. Many hosts replace the whole app folder each time you deploy, which would delete your uploads. So pick a folder outside the app folder, for example /home/<your account>/haimdall-data, and give it to HAIMDALL as HAIMDALL_DATA_DIR (next step). HAIMDALL creates it if it doesn't exist.
2. Settings
Set these as environment variables in your host's control panel. Or, if your host has no screen for them, put them in a file called .env in the HAIMDALL folder. The zip includes env.example to start from.
DATABASE_URL: the database connection address from step 1 of What you need.SESSION_SECRET: a long random value, at least 32 characters. Any password generator will do. Keep it the same forever: changing it signs everyone out.HAIMDALL_DATA_DIR: the data folder you chose.NODE_ENV=production.Optional:
HAIMDALL_SETUP_CODE, a code of your own (at least 12 characters) for creating the first administrator. Without it, HAIMDALL makes one up and you read it from the log or a file (step 5).Optional:
HAIMDALL_LICENCE(you can also enter the key in the editor) andHAIMDALL_PUBLIC_URL(you can also set it in the editor).
Every setting is described in Configuration Reference.
3. Upload HAIMDALL
Unzip haimdall-node-<version>.zip. It contains one folder, haimdall. Upload the contents of that folder to your app's folder on the host (or upload the zip and unzip it there).
In your host's Node.js app settings:
Start file (or "entry point", "application startup file"):
server.js.Node.js version: 22 or later.
Application type: "other" or "custom", not "Next.js": a Next.js preset would try to build it.
If the host asks for a build command, leave it empty or use
npm run build: in this package it does nothing, because HAIMDALL is already built. If it runsnpm install, that's fine too: the package's.npmrcmakes it change nothing.
Hosts that delete node_modules (Hostinger does)
Some hosts delete an uploaded node_modules folder and run npm install themselves. Hostinger always does: its build log says "Removing node_modules from the uploaded source", and the app then fails with Cannot find module 'next'. For those hosts, upload this form of the folder instead:
Copy the
haimdallfolder to a new one (keep the original as it is).In the copy, delete
node_modulesand.npmrc.Delete
package.json, then renamepackage.with-dependencies.jsontopackage.json.Zip the contents of the copy, so
server.jsis at the top of the zip, not inside a folder, and upload that zip.
The host's npm install then downloads the exact package versions this release was built with. Nothing is built.
Important
On Hostinger, make sure the website's saved build settings say application type Other, entry file server.js and output directory .. Hostinger detects "Next.js" on the first upload and saves that. Its later redeploys, for example the one it starts when you change a setting in hPanel, then fail with "Next.js build produced no standalone server or static output".
Hostinger also runs each deploy from a new folder, so on Hostinger HAIMDALL_DATA_DIR isn't optional: without it, uploads are lost at every deploy.
4. Start it
Start (or restart) the app from the control panel. The first start sets up the database by itself, which takes a few seconds. If your host shows the app's log, look for [startup] database is up to date. If HAIMDALL can't reach the database, it stops and the log says why.
5. Create the first administrator
Open https://<your site>/login. A new installation shows Set up HAIMDALL. Enter:
the setup code: the
HAIMDALL_SETUP_CODEyou chose, or the code HAIMDALL made up. You'll find it in the app's log, on the line starting[setup], and in the filesetup-code.txtin your data folder (open it with your host's file manager). A new code is made each time the app restarts;your name, email address and a password (at least 10 characters).
Click Create administrator and sign in. You're now in the editor, and the setup code stops working: it's only for the very first account.
Note
The setup code stops someone else who finds your brand-new site before you from taking it over. Too many wrong codes pause the form for a few minutes.
6. Finish setting up
HAIMDALL runs as a 7-day free trial until you enter your licence key on System › Licence key (or set HAIMDALL_LICENCE). Follow its Setup guide: it takes you through your team's accounts, languages, the look of your help site, the first articles and, last of all, opening the site to customers. Steps 6 to 8 of Installing HAIMDALL describe them, and apply here too.
Your host provides HTTPS for your site's address, so you don't need a separate reverse proxy.
Upgrading
Back up the database (your database provider's backup or
pg_dump) and the data folder.Upload the new version's folder in place of the old one (on Hostinger and other hosts that delete
node_modules, prepare it as in Hosts that delete node_modules first). Keep your settings and the data folder.Restart the app. HAIMDALL updates the database at start-up, and adds any new interface text to the data folder; your own edits and translations are kept.
If something goes wrong
The log says
Cannot find module 'next'(or another module): your host didn't keep the uploadednode_modulesfolder. Prepare the folder as in Hosts that delete node_modules and deploy again: the host'snpm installthen downloads the packages. Nothing is built, so this works on hosts that can't build Next.js, such as Hostinger.Hostinger shows "Build failed" with "Next.js build produced no standalone server or static output" (often right after you changed a setting in hPanel): the website's saved build settings still say Next.js. The site keeps running the previous build. Set the application type to Other, the entry file to
server.jsand the output directory to., then redeploy.The site shows an error or doesn't start: check the app's log. The most common causes are a wrong
DATABASE_URL, a database that doesn't accept outside connections, or a Node.js version older than 22.Uploaded images disappear after a deploy:
HAIMDALL_DATA_DIRisn't set, or points inside the app folder. Set it to a folder outside the app folder, then upload the images again.You can't find the setup code: set
HAIMDALL_SETUP_CODEto a code of your own and restart the app.Everyone is signed out after every deploy:
SESSION_SECRETis changing. Set it once, in the host's settings.
See Backups for what to back up, and the Security Checklist before you go live.
Adding a setting in Hostinger's hPanel
To add one environment variable to a running site, for example HAIMDALL_DATA_DIR:
Sign in to hPanel and open Websites. Next to the website, click Dashboard.
In the website dashboard's sidebar, open Environment variables.
Click Add environment variable. Enter the key exactly (capitals and underscores) and the value with no quotes, e.g.
/home/<account user>/haimdall-data.Click Apply changes. Your other settings stay as they are: you don't retype them.
Hostinger restarts the app with the new setting and also starts a redeploy, which needs the saved build settings described above. HAIMDALL creates the data folder itself when it starts.
Setting up Hostinger with an AI assistant
You need an AI assistant that can work with your Hostinger account, for example Claude with Hostinger's MCP server (hostinger-api-mcp) connected, and a PostgreSQL database (step What you need above). Give the assistant the HAIMDALL package, then paste the prompt below, with your website's address filled in. It asks you for the database address, deploys HAIMDALL with the right settings, checks it starts, and gives you the setup code. You then create the first administrator yourself, so your password never passes through the assistant.
You are setting up **HAIMDALL**, a help-centre application, on my **Hostinger** account as a **Node.js
web app**. Use the Hostinger tools you have (for example the Hostinger API MCP server). Work step by
step, tell me what you're doing as you go, and stop and ask me if anything doesn't match what's
described here.
**FILL IN — website:** the Hostinger website (domain) to install it on: `________________`
**FILL IN — database:** my PostgreSQL connection address (from Neon, Supabase or another provider; with
Neon, the **direct** address, not the "-pooler" one): I'll paste it when you ask for it.
The package is `haimdall-node-<version>.zip`. It unzips to one folder, `haimdall/`, that is **already
built**: `server.js`, `node_modules/`, `.next/`, `public/`, `drizzle/`, `tools/`, `defaults/`, `data/`,
`package.json`, `.npmrc`, `package.with-dependencies.json`, `env.example`, `INSTALL.txt`. Read
`INSTALL.txt` first.
## Rules
- **Don't run `next build`, `npm run build` with Next, or install build tools.** Hostinger's build
servers can't run Next.js's compiler (it needs a newer GLIBC). The package doesn't need building:
its `build` script only prints a message.
- **Don't change anything else on my account**: other websites, DNS, email, or my plan. **Don't buy
anything.** If the website doesn't exist, or the plan can't run Node.js apps, stop and tell me.
- **Secrets:** generate `SESSION_SECRET` and `HAIMDALL_SETUP_CODE` yourself (random). Store them only
in the app's environment variables. Never put secrets in files you upload, in chat summaries
(except the setup code, which I need), or anywhere public.
## Steps
1. **Check the website.** Confirm the website exists on my account and supports Node.js apps, and find
the Node.js versions it offers: HAIMDALL needs **Node.js 22 or later**.
2. **Choose a data folder outside the app folder.** HAIMDALL keeps uploaded images and attachments in
a data folder. Hostinger replaces the app's files on each deploy, so the data folder must be
**outside** the app's folder, in my account's home directory, for example
`/home/<account user>/haimdall-data`. Find my account's home directory and use that path.
3. **Ask me for the database address** (DATABASE_URL). Don't guess it, and don't create a database
unless I ask you to.
4. **Prepare the settings** (environment variables for the Node.js app):
- `DATABASE_URL` = the address I gave you
- `SESSION_SECRET` = 64 random characters (letters and digits)
- `HAIMDALL_DATA_DIR` = the data folder from step 2
- `HAIMDALL_SETUP_CODE` = a random code of 16 letters and digits in groups of 4, e.g. `K7QM-2XPA-9RTB-4HWN`
- `HAIMDALL_PUBLIC_URL` = `https://<the website>`
- `NODE_ENV` = `production`
- `HAIMDALL_LICENCE` = only if I give you a licence key (I can also enter it later in HAIMDALL).
5. **Prepare the Hostinger form of the package.** Hostinger deletes an uploaded `node_modules` folder
before it starts an app ("Removing node_modules from the uploaded source" in the build log), so the
package as shipped would fail with `Cannot find module 'next'`. On my computer, before uploading:
- copy the `haimdall/` folder to a new folder (leave the original as it is);
- in the copy, delete `node_modules/` and `.npmrc`;
- delete `package.json`, then rename `package.with-dependencies.json` to `package.json`;
- zip the **contents** of the copy, so `server.js` and `package.json` are at the top of the zip, not
inside a folder.
Hostinger's `npm install` then downloads the same package versions the bundle was built with. It
still builds nothing: the `build` script only prints a message.
6. **Deploy the app.** Upload that zip as the website's Node.js app, with:
- application type: other / custom (not Next.js: that would try to build it)
- entry / start file: `server.js`
- Node.js version: 22 (or the newest available, 22 or later)
- build command: none, or `npm run build` (a no-op in this package)
- the environment variables from step 4.
Then start (or restart) the app.
Also save these same settings as the website's **stored** build settings (with Hostinger's MCP
server: `hosting_nodejs_update-build-settings`, app type `other`, entry file `server.js`, output
directory `.`). A build started through the API uses the values sent with it, but hPanel's own
redeploys use the stored ones. Hostinger detects a Next.js app on the first upload and stores
"Next.js". Left that way, the next time I save a setting in hPanel, its redeploy fails with
"Next.js build produced no standalone server or static output".
7. **Check it started.** Open `https://<the website>/login`. Within a minute or two it should show
**"Set up HAIMDALL"**. The first start creates the database tables. If the app's log is available,
look for `[startup] database is up to date`.
- If the log says **`Cannot find module 'next'`** (or another missing module), the zip still had the
shipped `package.json`: redo step 5 and deploy again.
- If the log mentions the database, check `DATABASE_URL` (Neon: the direct address, with
`?sslmode=require`), and that the database accepts outside connections.
- Any other error: show me the last 30 lines of the log and stop.
8. **Hand over to me.** Tell me:
- the address to open: `https://<the website>/login`;
- the **setup code** (`HAIMDALL_SETUP_CODE`): on that page I enter it with my name, email and a new
password to create the first administrator. Remind me it only works once;
- the data folder you chose, and that it (and the database) is what to back up;
- that HAIMDALL runs as a 7-day free trial until a licence key is entered (System › Licence key,
unless you set `HAIMDALL_LICENCE`), and opens its Setup guide.
Don't create the administrator account yourself: I'll do it, so the password is never in this chat.
**Upgrading later** (if I ask):
1. Back up first: the database and the data folder.
2. Check that `HAIMDALL_DATA_DIR` is among the app's environment variables (the values are hidden;
the names are enough). If it's missing, stop and ask me to add it in hPanel (see "Adding one
setting in hPanel" below) before you deploy. Without it, every deploy starts with an empty data
folder, because each Hostinger build runs from a new folder. **Don't** set it with a "replace
environment variables" tool: that replaces the whole set, and you can't read the other values back.
3. Prepare the new package exactly as in step 5, then deploy it as in step 6, keeping the same
settings.
4. Check it as in step 7: `/login` shows the normal sign-in page (not "Set up HAIMDALL"), and the log
says `[startup] database is up to date`. Database changes are applied when it starts.
**Adding one setting in hPanel** (instructions for me, the account owner):
1. Sign in to hPanel and open **Websites**. Next to the website, click **Dashboard**.
2. In the website dashboard's sidebar, open **Environment variables**.
3. Click **Add environment variable**. Enter the key exactly, e.g. `HAIMDALL_DATA_DIR` (capitals and
underscores), and the value with no quotes, e.g. `/home/<account user>/haimdall-data`.
4. Click **Apply changes**. The existing settings stay as they are: you don't retype them.
5. Hostinger restarts the app with the new setting, and also starts a redeploy. Wait a minute, then
open `/login` to check it's up.
- If the redeploy shows **"Build failed"** with "Next.js build produced no standalone server or
static output", the site's stored build settings still say Next.js. The site keeps running the
previous build, which has already restarted with your new setting. Fix the stored settings so it
doesn't happen again: in the website dashboard open the Node.js **build settings** (or ask your AI
assistant) and set the application type to **Other**, the entry file to `server.js` and the output
directory to `.`, then redeploy.
HAIMDALL creates the data folder itself the first time it starts.