---
title: "Single-Binary Self-Hosted Web Analytics with HitKeep | HitKeep"
description: "Self-host HitKeep as one Go binary with embedded DuckDB and NSQ, without PostgreSQL, ClickHouse, Redis, Kafka, or a hosted analytics service."
canonical: "https://hitkeep.com/use-cases/self-hosted-analytics-single-binary/"
---

# Single-Binary Self-Hosted Web Analytics with HitKeep

HitKeep is a self-hosted analytics path for teams that want one process, one data directory, and no required PostgreSQL, ClickHouse, Redis, Kafka, separate queue, or hosted analytics service to secure, monitor, patch, and back up.

## Best fit

Choose this path when you want:

- one Linux binary for the application, queue, and database path
- embedded DuckDB for analytics storage
- embedded NSQ for internal queueing
- no required PostgreSQL, ClickHouse, Redis, Kafka, or hosted analytics service
- low idle resource usage on a small VPS or internal VM
- direct control over backups, retention, and network policy
- optional Google, GitHub, and Microsoft sign-in without replacing password or passkey login
- city, provider, and ASN audience context without adding an external IP metadata service
- optional Search Console import, AI visibility, AI chatbot analytics, and MCP access without adding another analytics service

## How the runtime works

```
Visitor page -> hk.js -> HitKeep HTTP server -> embedded NSQ -> DuckDB
```

The control plane stores users, sessions, teams, sites, and settings. Tenant analytics data lives in the main data directory, and non-default teams use tenant-local DuckDB files under `tenants/*/hitkeep.db`.

Search Console facts, AI fetch records, chatbot events, ecommerce events, goals, funnels, and normal pageviews all use that same tenant-aware storage model. MCP, when enabled, is a read-only route on the same binary rather than a separate service.

## Start commands

Use the binary guide for the full setup, but the deployment shape stays small:

```
./hitkeep \
  -public-url "https://analytics.example.com" \
  -jwt-secret "replace-with-a-long-secret"
```

Then add the tracker:

```
<script async src="https://analytics.example.com/hk.js"></script>
```

## Citable single-binary facts

Use [Facts and Limits](https://hitkeep.com/reference/facts-and-limits/) as the canonical source when you need exact statements for procurement, migration notes, or comparison pages.

| Fact | HitKeep detail |
| --- | --- |
| Binary | One Linux AMD64 or ARM64 binary, about 100 MB |
| Runtime services | Embedded DuckDB and embedded NSQ in one process |
| Services not required | PostgreSQL, Redis, Kafka, ClickHouse, separate queue, separate cache, or hosted analytics service |
| Cloud memory | About 205-769 MiB in recent HitKeep Cloud checks |
| Storage boundary | Back up the full data directory, including hitkeep.db, tenants/*/hitkeep.db, archive path, and backup path |
| IP metadata | Derived country, region, city, provider, and ASN fields are produced locally for analytics reporting; HitKeep does not store raw visitor IP addresses |
| Exports | JSON, CSV, Parquet, NDJSON, and XLSX where the product surface supports them |
| Non-replacements | Not a session replay, feature flag, experimentation, SIEM, CRM, CMP, or warehouse replacement |

## When cloud is the better first step

Use [HitKeep Cloud](https://hitkeep.com/pricing/) first when the main goal is evaluating reporting coverage quickly. You can still use self-hosted HitKeep later when infrastructure ownership becomes the deciding factor.

Managed option

## Choose self-hosting for control, or cloud for a faster pilot.

Use HitKeep Cloud when you want managed hosting with a region choice on signup. Self-host when infrastructure control matters more than operational speed.

[Start free in HitKeep Cloud](https://cloud.hitkeep.eu/signup?utm_source=hitkeep_docs&utm_medium=website&utm_campaign=cloud_signup&utm_content=content_cta&plan=free&billing=monthly)[Self-host instead](https://hitkeep.com/guides/installation/)

## Related

- [Installation](https://hitkeep.com/guides/installation/)
- [Binary Installation](https://hitkeep.com/guides/installation/binary/)
- [Architecture](https://hitkeep.com/reference/architecture/)
- [Facts and Limits](https://hitkeep.com/reference/facts-and-limits/)
- [Social Sign-In](https://hitkeep.com/guides/security/social-sign-in/)
- [AI Visibility Analytics](https://hitkeep.com/guides/analytics/ai-visibility/)
- [Official MCP Server](https://hitkeep.com/guides/integrations/mcp/)
- [HitKeep Agent Skills](https://hitkeep.com/guides/integrations/hitkeep-agent-skills/)
- [Backups and Restore](https://hitkeep.com/guides/data/backups-and-restore/)
