docker.recipes

Ackee Analytics

beginner

Self-hosted, privacy-focused web analytics alternative.

Overview

Ackee is a self-hosted, privacy-first web analytics platform created by Tobias Reich as a lightweight alternative to Google Analytics. Built with Node.js, Ackee focuses on collecting essential website metrics without compromising user privacy - it doesn't use cookies, fingerprinting, or personal data collection, making it GDPR compliant by design. The platform provides clean, minimalist dashboards showing visitor counts, page views, referrers, and device information while respecting user anonymity. This stack combines Ackee with MongoDB to create a complete analytics solution where Ackee handles the web interface and data collection while MongoDB stores all analytics data in its flexible document format. MongoDB's schema-less design perfectly accommodates Ackee's varied analytics data structures, from simple page views to complex visitor patterns, while its aggregation framework enables efficient real-time analytics queries. This combination is ideal for privacy-conscious website owners, small businesses, bloggers, and organizations that need website insights without sacrificing user privacy or depending on third-party analytics services that may track users across sites.

Key Features

  • Cookie-free tracking with automatic visitor anonymization and IP address hashing
  • Real-time analytics dashboard showing live visitor counts and page views
  • Detailed referrer tracking including social media, search engines, and direct traffic sources
  • Device and browser statistics without fingerprinting or personal identification
  • Multi-domain support allowing analytics for multiple websites from single dashboard
  • MongoDB aggregation pipeline integration for complex analytics queries and custom reports
  • Lightweight JavaScript tracking script with minimal impact on website performance
  • REST API access for programmatic data retrieval and custom integrations

Common Use Cases

  • 1Privacy-focused websites requiring GDPR compliance without cookie consent banners
  • 2Small business websites needing basic traffic analytics without Google Analytics dependency
  • 3Personal blogs and portfolios tracking visitor engagement and popular content
  • 4Educational institutions monitoring website usage while protecting student privacy
  • 5Non-profit organizations analyzing web traffic without compromising donor privacy
  • 6Development agencies offering privacy-compliant analytics to privacy-conscious clients
  • 7Corporate intranets tracking internal resource usage without employee monitoring concerns

Prerequisites

  • Docker and Docker Compose installed on host system
  • Minimum 1GB RAM available (512MB for MongoDB, 256MB for Ackee, plus system overhead)
  • Port 3000 available for Ackee web interface access
  • Environment variables ACKEE_USERNAME and ACKEE_PASSWORD configured for authentication
  • Basic understanding of web analytics concepts and JavaScript integration
  • Website access for embedding Ackee tracking script in HTML pages

For development & testing. Review security settings, change default credentials, and test thoroughly before production use. See Terms

docker-compose.yml

docker-compose.yml
1services:
2 ackee:
3 image: electerious/ackee:latest
4 container_name: ackee
5 environment:
6 - ACKEE_MONGODB=mongodb://mongodb:27017/ackee
7 - ACKEE_USERNAME=${ACKEE_USERNAME}
8 - ACKEE_PASSWORD=${ACKEE_PASSWORD}
9 ports:
10 - "3000:3000"
11 depends_on:
12 - mongodb
13 networks:
14 - ackee-network
15 restart: unless-stopped
16
17 mongodb:
18 image: mongo:6
19 container_name: ackee-mongodb
20 volumes:
21 - mongo-data:/data/db
22 networks:
23 - ackee-network
24 restart: unless-stopped
25
26volumes:
27 mongo-data:
28
29networks:
30 ackee-network:
31 driver: bridge

.env Template

.env
1# Ackee Analytics
2ACKEE_USERNAME=admin
3ACKEE_PASSWORD=secure_ackee_password

Usage Notes

  1. 1Dashboard at http://localhost:3000
  2. 2Login with username/password
  3. 3Create domains and get tracking script
  4. 4No cookies, GDPR compliant
  5. 5Minimal, privacy-first design

Individual Services(2 services)

Copy individual services to mix and match with your existing compose files.

ackee
ackee:
  image: electerious/ackee:latest
  container_name: ackee
  environment:
    - ACKEE_MONGODB=mongodb://mongodb:27017/ackee
    - ACKEE_USERNAME=${ACKEE_USERNAME}
    - ACKEE_PASSWORD=${ACKEE_PASSWORD}
  ports:
    - "3000:3000"
  depends_on:
    - mongodb
  networks:
    - ackee-network
  restart: unless-stopped
mongodb
mongodb:
  image: mongo:6
  container_name: ackee-mongodb
  volumes:
    - mongo-data:/data/db
  networks:
    - ackee-network
  restart: unless-stopped

Quick Start

terminal
1# 1. Create the compose file
2cat > docker-compose.yml << 'EOF'
3services:
4 ackee:
5 image: electerious/ackee:latest
6 container_name: ackee
7 environment:
8 - ACKEE_MONGODB=mongodb://mongodb:27017/ackee
9 - ACKEE_USERNAME=${ACKEE_USERNAME}
10 - ACKEE_PASSWORD=${ACKEE_PASSWORD}
11 ports:
12 - "3000:3000"
13 depends_on:
14 - mongodb
15 networks:
16 - ackee-network
17 restart: unless-stopped
18
19 mongodb:
20 image: mongo:6
21 container_name: ackee-mongodb
22 volumes:
23 - mongo-data:/data/db
24 networks:
25 - ackee-network
26 restart: unless-stopped
27
28volumes:
29 mongo-data:
30
31networks:
32 ackee-network:
33 driver: bridge
34EOF
35
36# 2. Create the .env file
37cat > .env << 'EOF'
38# Ackee Analytics
39ACKEE_USERNAME=admin
40ACKEE_PASSWORD=secure_ackee_password
41EOF
42
43# 3. Start the services
44docker compose up -d
45
46# 4. View logs
47docker compose logs -f

One-Liner

Run this command to download and set up the recipe in one step:

terminal
1curl -fsSL https://docker.recipes/api/recipes/ackee-analytics/run | bash

Troubleshooting

  • Ackee shows 'Database connection failed': Verify MongoDB container is running and ACKEE_MONGODB environment variable points to mongodb:27017/ackee
  • Login fails with correct credentials: Check ACKEE_USERNAME and ACKEE_PASSWORD environment variables are properly set and container has restarted after changes
  • No tracking data appears in dashboard: Ensure tracking script is properly embedded in website HTML and domain is correctly configured in Ackee settings
  • MongoDB data loss after container restart: Verify mongo-data volume is properly mounted and has sufficient disk space for analytics data storage
  • Ackee interface loads slowly or times out: Increase MongoDB memory allocation or check for high analytics data volume requiring database optimization

Community Notes

Loading...
Loading notes...

Download Recipe Kit

Get all files in a ready-to-deploy package

Includes docker-compose.yml, .env template, README, and license

Ad Space