Show HN: Pug.sh – open-source product analytics

BajajScooter1 pts0 comments

Pug — Open Source Product Analytics

Skip to content Open beta — free Open-source product analytics.<br>Pug records what happens in your product — page views, clicks, scrolls, custom events —<br>and ties every event to a person.<br>Ask questions with trends, funnels, retention, and user flows.<br>Self-host the whole stack, or use the free cloud.

Start free Live demo<br>GDPR EU‑hosted

user-09996<br>ext cust_009996

1,633<br>Events

317<br>Sessions

215<br>Pageviews

Created May 30 First seen 123d ago Last seen 4d ago Android 11 New York City, US<br>Activitylast 60 days

Identified properties1 trait<br>nameDiana Jones

Recent activitylast 10 events<br>app_close 4d ago<br>scroll 4d ago 72%<br>page_view 4d ago<br>app_open 4d ago<br>checkout_started 4d ago USD 416.21<br>add_to_cart 4d ago prod-0198<br>search 4d ago shirt

Get started First events in two minutes.<br>Initialize the SDK and auto-tracking starts immediately — no event plan, no instrumentation sprint. Call identify() when someone signs in; their anonymous history merges into their profile.

WebFlutterNode<br>Copy<br>import { init, identify, track } from '@poluruprvn/pug-web'

init('your-project-id', { apiKey: 'pub_your_key' })

// Page views, clicks, scrolls, form interactions, rage clicks,<br>// and dead clicks are captured automatically from here on.<br>identify('user_123', { email: '[email protected]', plan: 'pro' })<br>track('signup', { plan: 'pro' })<br>track('order_completed', { amount: 49.0, currency: 'USD' })<br>import 'package:pug_flutter_sdk/pug_flutter_sdk.dart';

await Pug.init('your-project-id', const PugOptions(apiKey: 'pub_your_key'));

// Auto-tracking starts immediately. Identify users on sign-in:<br>await Pug.identify('user_123', traits: {'plan': 'pro'});

// Typed methods for well-known events (custom props go in extras):<br>Pug.track.signup(extras: {'plan': 'pro'});<br>import { Pug } from 'sdk-node'

const pug = new Pug({ apiKey: process.env.PUG_API_KEY }) // private key, prv_…

// Server events name the user explicitly — no ambient session.<br>pug.track('user_123', 'order_completed', { amount: 49.0, currency: 'USD' })<br>await pug.identify('user_123', { email: '[email protected]', plan: 'pro' })<br>// Private keys can also read: profiles and insight queries.<br>const profile = await pug.profiles.getByExternalId('user_123')

Captured automatically page_view every route change<br>click element, text, selector<br>scroll max depth per page<br>form_submit form interactions<br>rage_click frustration signal<br>dead_click clicks that did nothing<br>Plus your own signup name any action you care about<br>order_completed with properties — amount, currency<br>video_play queryable like any built-in event<br>Added on ingest Geo (country, region, city)<br>Device & browser<br>UTM parameters

Live See events arrive in real time.

Every event shows up seconds after it happens — on a live map and in a stream, with the<br>page, device, and location already attached.

Ship a tracking change and know within seconds that it fires<br>Watch a launch land as it happens: how many people, from where, on which pages<br>Filter to the event behind a new feature and watch the first real users hit it

Unified profiles One profile per person, not per device or session.

The profile you saw at the top of this page is the core of Pug: every session, trait,<br>and event a person ever generated, in one searchable timeline.

Before sign-in, events accrue to an anonymous ID<br>identify(userId) merges that history into one profile<br>Works across devices: web today, app tomorrow — same person<br>Traits (plan, email, anything) live on the profile and filter every insight

Unified profile anon_7f3a92 user_123<br>page_view anon<br>scroll anon<br>add_to_cart anon<br>identify('user_123') history joins<br>signup<br>order_completed

Insights Six ways to turn events into answers.<br>Every insight runs over raw events in ClickHouse — filter by any property, break down by any dimension, and get answers in seconds.

Trends<br>Time-series of any event. Count, unique users, avg per user, or sum/avg/min/max of a numeric property. Break down by up to 5 properties.

Funnels<br>Conversion across ordered steps, with drop-off and average time between steps.

Retention<br>Cohort heatmap from a start event and a return event — who comes back, and when.

Segmentation<br>One aggregate sliced by any dimension — built for KPI tiles and scorecards.

User flow<br>A Sankey of the paths users actually take between events — where they go next, where they drop.

Top K<br>Ranked values of any property — top pages, top referrers, top products — with an “others” bucket.

Trends · signups, last 30 days

Funnel · signup → purchase 100%

Signup<br>68%

Onboarding<br>41%

Activation<br>23%

Purchase

Retention · weekly cohorts Cohort W0W1W2W3W4W5W6 Apr 27 100624841363331 May 4 1005845393532 May 11 10064514438 May 18 100614740 May 25 1006652 Jun 1 10063

User flow · after page_view page_view 100% of sessions, next step →<br>search 34% add_to_cart 22% checkout_started 12% session_end 32%

Dashboards The numbers you check every morning, on one board.

Pin any insight as a tile. The whole board shares one...

events event identify plan profile user_123

Related Articles