# Subscription figures

**Summary:** Subscription figures show saved counts of active subscriptions. A person with several subscriptions counts more than once.

- Role: [Technical Support](https://www.subrite.no/technical-support)
- Source: https://www.subrite.no/technical-support/insights-subscriptions
- Updated: 2026-09-28
- Markdown index: https://www.subrite.no/technical-support/llms.txt

New sales, seats and payments are outside this measure.

<a id="data-and-price-classification"></a>
## Data and price classification

`StatsStoreService.processAndSaveSubscriptionSummary` counts `MemberPackage.id` where the subscription status is Active. It includes subscriptions with renewal off and those in introductory periods.

Rows in `SubscriptionSummary` are grouped by plan, package, payment provider, introductory-period flag and renewal flag. Missing payment providers are stored as `none`.

The saved plan price is the sum of plan-product prices for non-optional, Published products. Paid requires this value above zero; Free requires zero; All removes the price condition.

A zero introductory payment on a positive-price plan therefore belongs to Paid. Neither successful payments nor an individual subscription’s custom price determines this classification.

Sources: [snapshot writer](https://github.com/subrite/subrite-crm/blob/6cd1850569be3b1702ca736a19320c7626efb7bc/api-server/src/modules/stats/services/stats-store.service.ts#L111) and [price filter](https://github.com/subrite/subrite-crm/blob/6cd1850569be3b1702ca736a19320c7626efb7bc/api-server/src/modules/stats/utils/subscription-price-filter.ts#L11).

<a id="period-calculation"></a>
## Period calculation

`getHistoricalSubscriptionData` reads saved summaries within the requested tenant and date range. For each group and reporting period, it selects the maximum `createdAt` within that range.

The outer query sums quantities at that exact timestamp, then applies the Paid/Free condition. A weekly bar uses a saved count; it does not add seven daily counts.

Grouping selects plan ID, package ID or payment-provider value. Weeks start Monday. Daily windows end yesterday; longer periods can include the current incomplete period marked \*.

All time is bounded by the available snapshot history and a 550-period limit. Changing period resets its range; changing type or group retains the range.

Sources: [snapshot selection](https://github.com/subrite/subrite-crm/blob/6cd1850569be3b1702ca736a19320c7626efb7bc/api-server/src/modules/stats/repositories/subscription-summary.repository.ts#L70) and [timeline boundaries](https://github.com/subrite/subrite-crm/blob/6cd1850569be3b1702ca736a19320c7626efb7bc/frontend/src/app/%28admin%29/admin/%28panel%29/analytics/statistics/utils/timeline/resolveTimelineWindow.ts#L53).

<a id="named-groups-others-and-totals"></a>
## Named groups, Others and totals

The page defaults to Paid, Subscription plan, five displayed series, Weekly and the last 12 weeks. Five reserves four named groups and one Others series; All allows 99 named groups.

The formatter ranks groups by quantity in the latest nonempty period. It retains those group IDs across the range.

Others appears only when that latest period has more groups than the named-group limit. An older group outside the selected IDs is omitted when that condition is false. Total also omits that group because it sums only returned series.

This follows the formatter’s branch conditions. No production dataset was used to reproduce the omission.

Details draws stacked group counts. Total sums every returned group for each period, including hidden Details groups.

Hover totals and percentages instead use visible groups. Percentages round to whole numbers, except positive shares below 1% and between 99% and 100%.

Hidden-series state uses positional IDs shared by Details and Total. Hiding the first Details group can therefore hide Total; show all legend groups before switching views.

Sources: [series selection and Others](https://github.com/subrite/subrite-crm/blob/6cd1850569be3b1702ca736a19320c7626efb7bc/api-server/src/modules/stats/services/stats.services.ts#L813) and [chart aggregation](https://github.com/subrite/subrite-crm/blob/6cd1850569be3b1702ca736a19320c7626efb7bc/frontend/src/ui/StatsView/index.tsx#L450).

<a id="diagnose-a-discrepancy"></a>
## Diagnose a discrepancy

| Symptom | Check and interpretation |
| --- | --- |
| Paid differs from payment records | Compare saved base plan price with zero. Paid classifies plans, not receipts. |
| Live subscription total differs | Compare the snapshot timestamp and Active subscription count at that time. |
| Earlier group is missing | Compare latest-period IDs with older IDs and the condition that adds Others. |
| Total disappears after changing views | Restore the first Details legend group; its hidden positional ID is reused. |
| Chart is empty | Check the response and saved rows. Zero/missing values and API errors can all render empty. |

The sidebar requires analytics access and the insights feature; the data endpoint requires Dashboard READ. Check both gates when the page opens without figures.

For an exact-timestamp mismatch, inspect whether the snapshot batch shares one `createdAt`. Different timestamps could exclude rows; this remains a source-derived concern, not a confirmed defect.

<a id="verification-limits"></a>
## Verification limits

Source checked on 28 September 2026 at `6cd1850569be3b1702ca736a19320c7626efb7bc`. Prior owner-session checks covered labels and dropdowns, not totals, legend behavior or ordinary-role access.

Production snapshot dates and refresh timing remain unverified. Use [Subscription figures in Administrators](https://www.subrite.no/administrators/insights-subscriptions?md=true) for graph interpretation and controls.

## Related pages

- [Subscription figures](https://www.subrite.no/administrators/insights-subscriptions?md=true): Subscription figures show saved counts of active subscriptions. A person with several subscriptions counts more than once.
