---
title: "Android pdf reader library for mobile devices"
canonical_url: "https://www.nutrient.io/guides/android/features/reader-view/"
md_url: "https://www.nutrient.io/guides/android/features/reader-view.md"
last_updated: "2026-05-30T02:20:01.181Z"
description: "Discover how to use Reader View for a better pdf reading experience on android devices."
---

# Optimize pdf viewing with android reader view

[Reader View](https://www.nutrient.io/guides/android/features/reader-view.md) presents the content of PDF documents in an easy-to-read, single-column view that’s optimized for mobile devices. It’s especially helpful for documents such as magazines, books, articles, and scientific papers.

Reader View only shows the textual content of a given PDF document. It also looks for headings and displays them bigger and/or bolder. All other elements — such as images, stylized page parts, and page headers and footers — are ignored in order to provide an improved reading flow.

Reader&nbsp;View tries to structure the text in the intended reading order. If you find documents where this isn’t the case and are able to share them, let us know.

| Normal View                                                                                                           | Reader View                                                                                                           |
| --------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- |
|  |  |

Reader View is still in its early stages, so if you have any feedback on how we could improve upon it, [contact us](https://support.nutrient.io/hc/en-us/requests/new).

To use Reader View, you need to have the Reader View component enabled in your license.

## How to use Reader View

Reader View comes integrated into [`PdfActivity`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-activity/index.html) and [`PdfUiFragment`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-ui-fragment/index.html), but it can also be manually integrated into any other view hierarchy inside your app.

### Enable Reader View in PdfActivity or PdfUiFragment

If your app is using [`PdfActivity`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-activity/index.html), a subclass of [`PdfActivity`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-activity/index.html), or a [`PdfUiFragment`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-ui-fragment/index.html), you can simply enable the preintegrated Reader View using the [`PdfActivityConfiguration.Builder#enableReaderView()`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.configuration.activity/-pdf-activity-configuration/-builder/enable-reader-view.html) method:

### KOTLIN

```kotlin

val configuration = PdfActivityConfiguration.Builder(context).enableReaderView(true).build()

```

### JAVA

```java

final PdfActivityConfiguration configuration =
    new PdfActivityConfiguration.Builder(context).enableReaderView(true).build();

```

When enabling Reader View like this, Nutrient will add a dedicated action with the `R.id.pspdf__menu_option_reader_view` ID to the primary toolbar, which, when tapped, will open Reader View for the currently displayed document.

#### Customizing the Reader View menu action

The default toolbar icon used by Reader View is called `R.drawable.pspdf__ic_reader_view`, and it can be replaced by setting a custom `pspdf__ActionBarIcons` style inside your theme:

```xml

<style name="MyApp.PSPDFKit.Theme" parent="PSPDFKit.Theme.Default">
    <item name="pspdf__actionBarIconsStyle">@style/MyApp.PSPDFKit.ActionBarIcons</item>
</style>

<style name="MyApp.PSPDFKit.ActionBarIcons" parent="PSPDFKit.ActionBarIcons">
    <item name="pspdf__readerViewIcon">@drawable/custom_reader_view_icon</item>
    <item name="pspdf__readerViewIconActivated">@drawable/custom_reader_view_icon_activated</item>
</style>

```

For additional guidance on toolbar customization (e.g. reordering or hiding of toolbar actions), refer to our [customizing menus](https://www.nutrient.io/guides/android/customizing-the-interface/customizing-menus.md) guide.

#### Programmatically showing Reader View

If you want to programmatically show Reader View inside your activity, you can do this by accessing the activity’s [`PSPDFKitViews`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-p-s-p-d-f-kit-views/index.html) object and calling its [`showView()`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-p-s-p-d-f-kit-views/show-view.html) method using [`PSPDFKitViews.Type#VIEW_READER`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-p-s-p-d-f-kit-views/-type/-v-i-e-w_-r-e-a-d-e-r/index.html):

### KOTLIN

```kotlin

pspdfKitViews.showView(PSPDFKitViews.Type.VIEW_READER)

```

### JAVA

```java

getPSPDFKitViews().showView(PSPDFKitViews.Type.VIEW_READER);

```

### Integrating into the custom view hierarchy

Reader View is represented by the [`PdfReaderView`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-reader-view/index.html) class, which is a subtype of Android’s [`FrameLayout`](https://developer.android.com/reference/android/widget/FrameLayout.html), and which can be added to any view hierarchy inside your app. The simplest way to do this is by using an XML layout file:

```xml

<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <!--... -->

    <com.pspdfkit.ui.PdfReaderView
        android:id="@+id/reader_view"
        android:layout_width="match_parent"
        android:layout_height="match_parent"/>

</FrameLayout>

```

Then retrieve the inflated [`PdfReaderView`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-reader-view/index.html) instance and set a loaded [`PdfDocument`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.document/-pdf-document/index.html) to it using the [`PdfReaderView#setDocument()`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-reader-view/set-document.html) method:

### MYACTIVITY.KT

```kt

val readerView = findViewById<PdfReaderView>(R.id.reader_view)
val configuration = PdfConfiguration.Builder().build()
readerView.setDocument(document, configuration)

```

### MYACTIVITY.JAVA

```java

final PdfReaderView readerView = findViewById(R.id.reader_view);
final PdfConfiguration configuration = new PdfConfiguration.Builder().build();
readerView.setDocument(document, configuration);

```

#### Available configuration options

When setting a document using [`PdfReaderView#setDocument()`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-reader-view/set-document.html), you need to pass in a [`PdfConfiguration`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.configuration/-pdf-configuration/-builder/index.html) instance as the second argument. This configuration can be used to customize the appearance of the loading spinner that is shown while [`PdfReaderView`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-reader-view/index.html) processes the document for display. Here’s the list of configuration options that [`PdfReaderView`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-reader-view/index.html) supports:

| Option                                                                    | Description                                                                                                                 |
| ------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- |
| <nobr>[`getLoadingProgressDrawable()`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.configuration/-pdf-configuration/loading-progress-drawable.html)</nobr> | Use this to change the loading spinner drawable that is shown while [`PdfReaderView`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-reader-view/index.html) processes the document for display. |
| [`getBackgroundColor()`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.configuration/-pdf-configuration/background-color.html)                              | Change the background color that is shown behind the loading spinner.                                                       |

When using [`PdfReaderView`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-reader-view/index.html) inside an activity that also hosts a [`PdfFragment`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.ui/-pdf-fragment/index.html), you can simply reuse the same [`PdfConfiguration`](https://www.nutrient.io/api/android/nutrient/com.pspdfkit.configuration/-pdf-configuration/-builder/index.html) instance that you also pass to your fragment, in order to share the same styling.
---

## Related pages

- [Enable night theme in Android PDF viewer](/guides/android/viewer/viewing-options/night-theme.md)
- [Right-to-left (RTL) support in our Android PDF viewer](/guides/android/miscellaneous/page-bindings.md)
- [Opening multiple PDFs in our Android viewer](/guides/android/features/working-with-multiple-documents.md)

