Configuring cohort analysis for a mobile application

NOVASOLUTIONS.TECHNOLOGY is engaged in the development, support and maintenance of iOS, Android, PWA mobile applications. We have extensive experience and expertise in publishing mobile applications in popular markets like Google Play, App Store, Amazon, AppGallery and others.
Development and support of all types of mobile applications:
Information and entertainment mobile applications
News apps, games, reference guides, online catalogs, weather apps, fitness and health apps, travel apps, educational apps, social networks and messengers, quizzes, blogs and podcasts, forums, aggregators
E-commerce mobile applications
Online stores, B2B apps, marketplaces, online exchanges, cashback services, exchanges, dropshipping platforms, loyalty programs, food and goods delivery, payment systems.
Business process management mobile applications
CRM systems, ERP systems, project management, sales team tools, financial management, production management, logistics and delivery management, HR management, data monitoring systems
Electronic services mobile applications
Classified ads platforms, online schools, online cinemas, electronic service platforms, cashback platforms, video hosting, thematic portals, online booking and scheduling platforms, online trading platforms

These are just some of the types of mobile applications we work with, and each of them may have its own specific features and functionality, tailored to the specific needs and goals of the client.

Showing 1 of 1 servicesAll 1735 services
Configuring cohort analysis for a mobile application
Medium
~2-3 business days
FAQ
Our competencies:
Development stages
Latest works
  • image_mobile-applications_feedme_467_0.webp
    Development of a mobile application for FEEDME
    756
  • image_mobile-applications_xoomer_471_0.webp
    Development of a mobile application for XOOMER
    624
  • image_mobile-applications_rhl_428_0.webp
    Development of a mobile application for RHL
    1054
  • image_mobile-applications_zippy_411_0.webp
    Development of a mobile application for ZIPPY
    947
  • image_mobile-applications_affhome_429_0.webp
    Development of a mobile application for Affhome
    862
  • image_mobile-applications_flavors_409_0.webp
    Development of a mobile application for the FLAVORS company
    445

Setting up cohort analysis for mobile app

Retention — the most important product metric. Day-1 retention 40% and Day-7 retention 20% mean different products with different problems. Cohort analysis answers: how do users who installed the app in the same week behave after 1, 7, 14, 30 days?

Aggregated DAU hides degradation: if new users arrive faster than old leave, DAU grows — but retention falls. Cohorts reveal this.

What's needed for cohort analysis

Two mandatory conditions: stable user_id and activation event. Without them, cohort doesn't build correctly.

User ID must be same on app reinstall — if generating new each time, user always in "new" cohort. Solutions:

  • iOS: Keychain to store generated UUID (survives app deletion)
  • Android: AccountManager or server-side ID after registration
  • After authorization: Analytics.setUserId(serverUserId) → user tied to account

Activation event — first action showing product value. For different apps different:

App type Activation event
Marketplace first_purchase
Streaming content_played (3+ minutes)
Fitness workout_completed
Game level_2_started
Social network first_post or 5_connections

Activation event choice affects what cohort shows. app_open — too broad, includes random users. premium_purchase — too narrow for full audience retention analysis.

Implementing cohort analysis

Firebase / BigQuery

Firebase builds Retention Chart in Analytics section itself, but with limited flexibility. For deep analysis — export raw data to BigQuery via Firebase → Integrations → BigQuery. Then SQL:

-- Cohort by installation weeks, 7-day retention
WITH cohorts AS (
    SELECT
        user_pseudo_id,
        DATE_TRUNC(MIN(PARSE_DATE('%Y%m%d', event_date)), WEEK) AS cohort_week,
        MIN(event_timestamp) AS first_open_ts
    FROM `project.analytics_*.events_*`
    WHERE event_name = 'first_open'
    GROUP BY user_pseudo_id
),
activity AS (
    SELECT DISTINCT
        user_pseudo_id,
        DATE_TRUNC(PARSE_DATE('%Y%m%d', event_date), WEEK) AS activity_week
    FROM `project.analytics_*.events_*`
    WHERE event_name = 'session_start'
)
SELECT
    c.cohort_week,
    DATE_DIFF(a.activity_week, c.cohort_week, WEEK) AS week_number,
    COUNT(DISTINCT c.user_pseudo_id) AS cohort_size,
    COUNT(DISTINCT a.user_pseudo_id) AS retained_users,
    ROUND(COUNT(DISTINCT a.user_pseudo_id) / COUNT(DISTINCT c.user_pseudo_id) * 100, 1) AS retention_pct
FROM cohorts c
LEFT JOIN activity a ON c.user_pseudo_id = a.user_pseudo_id
GROUP BY 1, 2
ORDER BY 1, 2

This query gives retention table by weeks.

Amplitude

In Amplitude, cohort analysis — native tool in Retention Analysis section. Configure:

  1. Starting Eventfirst_open or activation event
  2. Return Eventsession_start or app_open
  3. Grouping by days/weeks
  4. Breakdown by: install source, platform, app version

Amplitude allows comparing cohorts side-by-side — convenient to see if retention improved after product update.

Mixpanel

In Mixpanel Retention section builds classic retention matrix. Additionally Lifecycle — shows what percentage of users "resurrect" after long absence. For casual games this is important metric.

Behavioral cohorts

Besides time cohorts (by install date), useful behavioral cohorts — groups of users who did certain action:

# Example logic in BigQuery:
# Cohort: users who completed onboarding
# Question: what's their retention vs users who skipped onboarding?

If completed onboarding retention 2x higher — proof that onboarding needs improvement, not cutting.

What's included in the work

  • Audit of user_id stability in current implementation
  • Determining activation events with product manager
  • Setting up cohort analysis in Firebase + BigQuery / Amplitude / Mixpanel
  • SQL queries for custom cohort reports
  • Setting up behavioral cohorts for key hypotheses
  • Documentation and team handoff

Timeline

Cohort analysis setup in ready tool (Amplitude/Mixpanel): 1–2 days. BigQuery + custom SQL queries: 2–4 days. Cost calculated individually.