---
title: "Android PDF Viewer analytics | Nutrient SDK"
canonical_url: "https://www.nutrient.io/guides/android/features/analytics/"
md_url: "https://www.nutrient.io/guides/android/features/analytics.md"
last_updated: "2026-06-09T10:26:34.428Z"
description: "The Nutrient Analytics API lets you easily collect usage data based on a user’s activity taking place in Nutrient components."
---

# Analytics

The Nutrient Analytics API allows you to easily collect usage data based on a user’s activity taking place in Nutrient components.

The Nutrient Analytics API consists of:

- An [`Analytics`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.analytics/-analytics/index.html) object containing all constants that are related to the Analytics API

- An [`AnalyticsClient`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.analytics/-analytics-client/index.html) interface that you need to implement to capture analytics events

## Integration

The Nutrient Analytics API comes bundled with `PSPDFKitUI.xcframework`, so you don’t need to add any external packages. Just ensure you’re importing the `PSPDFKitUI` module in your file wherever you’re using this API.

### Enable analytics

To collect analytics data, you need to implement the [`AnalyticsClient`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.analytics/-analytics-client/index.html) interface. This interface will be notified of all events emitted by Nutrient, and it’s where you pass them to the analytics service of your choice.

Be aware that events are delivered on a **background thread**.

Create an instance of your [`AnalyticsClient`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.analytics/-analytics-client/index.html) when the app launches (preferably at the same time you’re initializing Nutrient) and register it with [`Nutrient.addAnalyticsClient()`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit/-nutrient/add-analytics-client.html):

### KOTLIN

```kotlin

val analyticsClient = MyAnalyticsClient()
Nutrient.addAnalyticsClient(analyticsClient)

```

### JAVA

```java

AnalyticsClient analyticsClient = new MyAnalyticsClient();
Nutrient.addAnalyticsClient(analyticsClient);

```
---

## Related pages

- [Events and notifications](/guides/android/events-and-notifications.md)
- [Understand PDF form events in Android SDK](/guides/android/events-and-notifications/forms.md)
- [Annotation events and notifications](/guides/android/events-and-notifications/annotation.md)
- [Analytics events](/guides/android/events-and-notifications/events.md)
- [Text selection events and notifications](/guides/android/events-and-notifications/text-selection.md)
- [PDF viewer events](/guides/android/miscellaneous/document-listeners.md)

