Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Learn Engagement Metrics | Core Metrics and Measurement
Product Analytics for Beginners

Engagement Metrics

Swipe to show menu

Understanding how users interact with your product is crucial for driving growth and improvement. Engagement metrics such as Daily Active Users (DAU), Monthly Active Users (MAU), stickiness, and session length provide clear signals about how often users return and how deeply they engage.

DAU measures the number of unique users who interact with your product in a single day. For instance, if you run a mobile game and 1,000 unique players open the app today, your DAU is 1,000.

MAU captures the number of unique users who engage with your product over a month. If 10,000 different people use your app at least once in June, your MAU for June is 10,000.

Stickiness is the ratio of DAU to MAU, typically expressed as a percentage. It shows what portion of your monthly users are active on a daily basis, highlighting how habit-forming your product is. A higher stickiness means users return frequently.

Session length tracks how much time users spend per visit. For example, if the average user spends 10 minutes each time they use your news app, that’s your average session length.

Suppose you manage three products: a social network, a weather app, and a budgeting tool. The social network may have high DAU and high stickiness, indicating users check it daily. The weather app may have moderate DAU but high session length during storms. The budgeting tool might have lower DAU but a steady MAU, as users check it mostly at the start or end of the month.

123456789101112131415161718192021222324252627282930313233343536
# Sample activity data: list of (user_id, date) tuples activity_log = [ (1, '2024-06-01'), (2, '2024-06-01'), (1, '2024-06-02'), (3, '2024-06-02'), (2, '2024-06-03'), (4, '2024-06-03'), (1, '2024-06-03'), (5, '2024-06-04'), (1, '2024-06-04'), (2, '2024-06-04'), (3, '2024-06-04'), ] def calculate_dau(activity_log, target_date): return len({user for user, date in activity_log if date == target_date}) def calculate_mau(activity_log, month): return len({user for user, date in activity_log if date.startswith(month)}) def calculate_stickiness(dau, mau): if mau == 0: return 0 return round((dau / mau) * 100, 2) # Calculating DAU for 2024-06-04 dau = calculate_dau(activity_log, '2024-06-04') # Calculating MAU for June 2024 mau = calculate_mau(activity_log, '2024-06') # Calculating stickiness ratio stickiness = calculate_stickiness(dau, mau) print("DAU:", dau) print("MAU:", mau) print("Stickiness (%):", stickiness)
Note
Note

High stickiness indicates strong user engagement and product habit formation.

Here is a breakdown of how the code above works:

First, the activity_log contains entries for user activity, where each record is a user ID and a date string. To calculate DAU, the code counts unique user IDs for a specific date. For example, on '2024-06-04', it finds all users active that day and counts how many are unique.

For MAU, the code looks for all unique users whose activity falls within the target month, such as '2024-06'. This shows how many different users interacted with your product during that month.

Stickiness is then calculated by dividing DAU by MAU and multiplying by 100 to get a percentage. This reveals what portion of your monthly users are also active daily - a direct indicator of how regularly users return.

By running this code, you can quickly see your DAU, MAU, and stickiness for any date and month, helping you spot trends or issues in user engagement.

1. What does a high stickiness ratio indicate about a product's user engagement?

2. Fill in the blank:

question mark

What does a high stickiness ratio indicate about a product's user engagement?

Select the correct answer

question-icon

Fill in the blank:

Stickiness is calculated as DAU divided by
Everything was clear?

How can we improve it?

Thanks for your feedback!

Section 2. Chapter 1

Ask AI

expand

Ask AI

ChatGPT

Ask anything or try one of the suggested questions to begin our chat

Section 2. Chapter 1
some-alt