Some test text!


Get started with Flutter

Welcome to PDFTron. PDFTron SDK can be integrated with Flutter for both Android and iOS.

Android & Flutter PDF library integration

See here for the get started guide for using the PDFTron Flutter SDK on iOS.

This guide will help you integrate a free trial of the PDFTron SDK into your Android applications using Flutter. Your free trial includes unlimited trial usage and support from solution engineers.

Get the Flutter source code


  • PDFTron SDK >= 6.9.0
  • Flutter >= 1.0.0
No trial license key required.
The trial of PDFTron SDK works without a license key. A commercial license key is required for use in a production environment. Please fill out our licensing form if you do not have a valid license key.
Keep your commercial license key confidential.
License keys are uniquely generated. Please make sure that it is not publicly available (e.g. in your public GitHub).


For simplicity, the following guide is based on a boilerplate Flutter app and uses Git Diff syntax to represent lines that have been added to or removed from the app.

  1. First follow the Flutter get started guides to install, set up an editor, and create a Flutter Project. The rest of this guide assumes your project is created by running flutter create myapp.

  2. Add the following dependency to your Flutter project in myapp/pubspec.yaml:

    	sdk: flutter
    +  pdftron_flutter:
    +   git:
    +	  url: git://
  3. Now add the following items in your myapp/android/app/build.gradle file:

    android {
        compileSdkVersion 29
        lintOptions {
    	disable 'InvalidPackage'
        defaultConfig {
    	applicationId "com.example.myapp"
    -       minSdkVersion 16
    +       minSdkVersion 21
    	targetSdkVersion 29
    +       multiDexEnabled true
    +       manifestPlaceholders = [pdftronLicenseKey:PDFTRON_LICENSE_KEY]
    	versionCode flutterVersionCode.toInteger()
    	versionName flutterVersionName
    	testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  4. In your myapp/android/app/src/main/AndroidManifest.xml file, add the following lines to the <application> tag:

    <!-- Enable usesCleartextTraffic in application attributes if you are 
    working with HTTP files. If you are only working with HTTPS files, this is not required.-->
    +	android:largeHeap="true"
    +	android:usesCleartextTraffic="true">

    Additionally, add the required permissions for your app in the <manifest> tag:

    <uses-permission android:name="android.permission.INTERNET" />
      <!-- Required to read and write documents from device storage -->
    +   <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
      <!-- Required if you want to record audio annotations -->
    +   <uses-permission android:name="android.permission.RECORD_AUDIO" />
  5. Add your PDFTron license key to the myapp/android/ file.


    Key can be left empty for a trial.

  6. If you are using the DocumentView widget, change the parent class of your MainActivity file (either Kotlin or Java) to FlutterFragmentActivity.

    import androidx.annotation.NonNull
    	import io.flutter.embedding.engine.FlutterEngine
    	import io.flutter.plugins.GeneratedPluginRegistrant
    	class MainActivity : FlutterFragmentActivity() {
    		override fun configureFlutterEngine(@NonNull flutterEngine: FlutterEngine) {

Next step

View a document

Get the answers you need: Support

PDFTron live tech update & run-through: Jan 20th at 11 am PT