Build Algolia
KINDAback to the verdict
Instant, typo-tolerant search over your own content without writing a search engine: Meilisearch on a small box behind Caddy, an idempotent indexing script, a search-only key for the browser, and a search box under 5 KB that works without JavaScript too.
Before step 1
Everything below is assumed from the first step. Tick each one when you actually have it, not when you plan to.
- installfree
Why Everything in this build runs on it: the server, the scripts, the tests.
Get it Download the LTS installer from nodejs.org, or install with your package manager (brew install node, or nvm install 22). Restart the terminal afterwards. open ↗
Verify
node --version prints v22 or higher - installfree
Why Every step below is a command you type or a file you edit.
Get it VS Code (code.visualstudio.com), Cursor or Zed. Open a folder for the project and use the editor's built-in terminal. open ↗
Verify
You can open a folder and run a command in its terminal - installfree
Why History for your code, and the way most hosts deploy.
Get it Install from git-scm.com or with your package manager, then run git init in the project folder once it exists. open ↗
Verify
git --version prints a version - accountabout $6 to $12 a month
Why Meilisearch holds the index in memory.
Get it Hetzner CX22 or similar, Ubuntu 24.04. open ↗
- installfree
Why The engine.
Get it curl -L https://install.meilisearch.com | sh, or the Docker image getmeili/meilisearch. open ↗
Verify
meilisearch --version prints - have readyfree
Why The indexer reads it.
Get it Markdown files, a JSON export, or a database connection string.
- accountroughly $10 a year, or free on an existing domain
Why search.yourdomain.com for the API.
Get it Register at Cloudflare Registrar, Porkbun or Namecheap, or use a subdomain of one you already own. You add one DNS record in the deploy phase. open ↗
- installfree
Why Automatic HTTPS in front of the Node process. Without TLS the browser features this relies on (and your visitors' trust) do not work.
Get it On the VPS: follow the install steps at caddyserver.com/docs/install for Ubuntu. One Caddyfile with your domain and a reverse_proxy line is the whole config. open ↗
Verify
caddy version prints a version on the server
Environment variables
These go in a .env file the app reads at startup. The pack's .env.example is this table as a file · copy it, never commit the filled-in version.
| Variable | Needed | Example | Where the value comes from |
|---|---|---|---|
MEILI_MASTER_KEYsecret | required | long-random | openssl rand -base64 32; admin key, server-side only. |
MEILI_URL | required | https://search.yourdomain.com | Public API address behind Caddy. |
MEILI_SEARCH_KEY | optional | ... | Generated in Phase 3; safe for the browser. |
CONTENT_DIR | required | ./content | Where the indexer reads from. |
The build, in order
Run it
Meilisearch bound to localhost with a master key, Caddy in front.
- terminal
meilisearch --master-key $MEILI_MASTER_KEY --http-addr 127.0.0.1:7700
Files
Caddyfile
done when · tick each as it passesIndex
Documents with id, title, url, body and tags; idempotent.
- terminal
mkdir search-index && cd search-index && git init && npm init -y && npm pkg set type=module && npm install meilisearch@0.4 mkdir -p content && cp .env.example .env
done when · tick each as it passesKeys
A search-only key for the browser; the master key never leaves the server.
done when · tick each as it passesThe box
Results as you type, highlighted, keyboard-driven, under 5 KB, degrades to a form.
done when · tick each as it passesOperate
Relevance tuningproduct builder
Synonyms, ranking rules, and a way to measure.
done when · tick each as it passes
That is the whole plan for Algolia. What it deliberately does not cover is below · check the gaps before you call it a replacement.
- Merchandising rules, AI ranking, the global edge: commerce money.
- the global distributed search network
- merchandising, rules and A/B testing
- AI ranking and personalization
- zero operations
- Faceted filters
- Multi-index federated search
Need the files? The project pack on the verdict page hands your agent the whole brief · more ai search.