Luna is a free, open-source menstrual cycle tracking companion. This policy explains exactly what data we collect, where it goes, and who touches it. We wrote it in plain language because you should know what happens to your data — especially health data — without needing a lawyer.
What we collect
To provide predictions and a personalized AI experience, Luna collects:
- Account info. Your email address and a bcryptjs-hashed password (12 rounds). We never see your plain-text password.
- Profile data. Your name (optional), date of birth (optional, max 2 edits), timezone, and week start preference.
- Health conditions. Self-reported conditions you select during onboarding — PCOS, endometriosis, thyroid disorders, hormonal birth control, perimenopause, and others. These tune the prediction engine. Stored as a validated allowlist array (10 possible values).
- Cycle data. Period start/end dates, ovulation dates, symptoms, moods, and personal notes. All date-parsed through timezone-aware normalizers.
- Chat messages. Everything you type to the AI assistant. Stored as UIMessage parts (not plain content) with auto-generated summaries after 30+ messages.
- AI traces. Model used, input/output token counts, cost, latency, and feature type — logged after every AI response for monitoring.
- Images. Any photos you upload for analysis. Stored as base64 in PostgreSQL with a 7-day TTL. Auto-deleted by a cron job.
- Personal facts.When you say "remember I have PCOS," Luna stores that fact in Supermemory for cross-session recall. Scoped per user via containerTag — no cross-user leakage.
Where your data lives — Neon PostgreSQL
All structured data lives in a Neon PostgreSQL database. Neon is a serverless Postgres platform running on AWS.
Neon was acquired by Databricks in May 2025. Privacy policy now falls under Databricks' legal framework. Luna uses Neon's HTTP serverless driver with cache: no-store to prevent Vercel from caching query results. Neon Trust Center · Security
AI processing — HackClub proxy
All AI chat goes through HackClub's infrastructure, a US 501(c)(3) nonprofit. Their proxy forwards prompts to OpenRouter, which then routes to xAI (Grok) and Anthropic (Claude). Web searches use HackClub's search API.
Full prompt logging. HackClub logs every AI prompt and response in full (jsonb), linked to your user ID and IP address. This includes anything you type to the AI — symptoms, cycle details, health questions.
No retention policy.There is no documented deletion schedule for these logs. HackClub's general privacy policy does not specifically address the AI proxy or search API.
Verifiable.HackClub's AI proxy code is fully open source. You can verify exactly what they log. But you cannot opt out of it.
Upstream: HackClub → OpenRouter → xAI/Anthropic. Each upstream provider has their own data policies. HackClub Privacy & Terms
Personal facts — Supermemory
When you tell Luna to remember something ("I have PCOS," "I'm allergic to ibuprofen"), that fact is stored in Supermemory v4 API for cross-session recall. Luna sends only personal facts — never cycle data or chat messages. Each user's facts are scoped via containerTag.
Supermemory is an early-stage company (Supermemory Inc., founded by Dhravya Shah). Their core engine is open source (MIT). Luna queries Supermemory with a 3-second AbortSignal timeout. Supermemory Privacy
Email — Resend
Transactional emails (welcome, password reset, OTP, login notifications) are sent via Resend. Emails go to the address you provided at signup. No marketing emails are sent. Luna uses the ADMIN_EMAIL environment variable for the from address. Resend Privacy
Data retention & your rights
- Images auto-deleted after 7 days. A cron job purges expired uploads. Images are stored as base64 in PostgreSQL (not an object store like S3).
- Export your data. Download all your cycle data as a JSON file through the chat or via the export route. Format: Luna JSON v1 with mStart, mEnd, ovulationDate, cycleLength, periodLength, notes.
- Account deletion.Coming soon through settings. Currently available by contacting us directly. All your data is permanently removed from Luna's database.
- HackClub logs.As noted above, HackClub logs AI prompts and responses with no documented retention. These logs are outside Luna's control. If you need full data sovereignty, self-host Luna with your own AI backend.
- Rate limiting. Sensitive endpoints (login, password reset, OTP, login-notification, subscribe) are rate-limited via Upstash Redis with in-memory fallback.
Security measures
- Password hashing. bcryptjs, 12 rounds. Plain-text passwords never stored.
- Content Security Policy. Per-request nonces generated in the request proxy. strict-dynamic for script loading. No unsafe-eval or unsafe-inline in production.
- Rate limiting. Sliding-window counters on auth endpoints via Upstash Redis (fallback to in-memory per-process).
- Input validation. Zod schemas on all API routes. Conditions restricted to a 10-element allowlist. Password capped at 128 characters to prevent bcrypt DoS.
- Third-party timeouts. AbortSignal.timeout on Supermemory (3s) and HackClub search (5s) calls.
- Email enumeration prevention. Registration route returns success even if email already exists.
- No logs in production. Email and error messages use placeholder addresses, not real user data.
Security audit by Kiro (May 2025). 10 fixes applied: Redis rate limiting, CSP hardening, Zod import validation, conditions allowlist, third-party timeouts, admin email env var, and more.
What we don't do
- Sell your data. To anyone. Ever.
- Show you ads. No ad networks, no ad tracking.
- Share data with insurers, employers, or data brokers.
- Train AI models on your conversations.
- Use tracking cookies or analytics.
- Share cycle data with a partner or doctor.
- Connect to wearable devices (no Apple Watch, Oura Ring, etc.).
Contact
Questions about this policy or how we handle your data?
This policy is part of Luna's open-source repository. You can see its history and suggest changes on GitHub.