AnyHabit is a streamlined, universal habit-tracking dashboard designed for Raspberry Pi, home servers, and Docker enthusiasts. It provides a minimalist interface to track positive growth or systematically reduce harmful routines.
Watch how AnyHabit tracks your progress and savings in real-time.
AnyHabit is designed to be "up and running" in seconds. You do not need Node.js or Python installed locally.
Requirements: Docker with the Compose plugin.
# 1. Clone the repository
git clone https://github.com/Sparths/AnyHabit.git
cd AnyHabit
# 2. Build and start everything
docker compose up -d --buildOpen http://localhost (or your device's IP) in your browser.
Tip
Your data is safely stored in a Docker volume (db_data) and will persist even if you stop or rebuild the containers.
By default, AnyHabit runs on port 80. If you need to change this (e.g., to run alongside other services on a Raspberry Pi), follow these steps:
- Create an environment file:
cp .env.example .env - Edit
.envand changeAPP_PORT=8080 - Restart with:
docker compose up -d
AnyHabit uses a modern, high-performance stack:
- Backend: FastAPI (Python 3.12-slim).
- Frontend: React 19 served via Nginx.
- Styling: Tailwind CSS 4 for a lightweight, modern UI.
- Database: SQLite for zero-config persistence.
- Reverse Proxy: Integrated Nginx configuration to route API requests seamlessly.
AnyHabit is an open-source, community-driven project! We would absolutely love your input to make it even better.
- 💡 Have an idea? We actively encourage feature requests! Open a Feature Request to share your ideas and discuss them with the community.
- 🐛 Found a bug? Help us squash it by Opening a Bug Report.
- 💻 Want to write code? We welcome Pull Requests! Please check out our Contributing Guidelines to get your local environment set up.
Whether it's a typo fix, a new feature, or a documentation update, all contributions are highly appreciated! Please ensure you follow our Code of Conduct when interacting with the community.
If you wish to modify the code and run it without Docker:
pip install -r backend/requirements.txt
mkdir -p backend/data
uvicorn backend.main:app --reload --host 0.0.0.0 --port 8000Note: Make sure to install dependencies from backend/requirements.txt.
cd frontend
npm install
# Set API URL to point to your local backend
VITE_API_URL=http://localhost:8000 npm run devThis addition explicitly tells visitors that they aren't just downloading a finished tool—they are invited to be part of the ongoing development process!
