advance_pdf_viewer_fork 2.0.0 copy "advance_pdf_viewer_fork: ^2.0.0" to clipboard
advance_pdf_viewer_fork: ^2.0.0 copied to clipboard

A flutter plugin for handling PDF files. Works on both Android & iOS

advance_pdf_viewer_fork #

A flutter plugin for handling PDF files. Works on both Android & iOS. Originally forked from that originally forked from

Pub Package

Installation #

Add advance_pdf_viewer_fork as a dependency in your pubspec.yaml file.

advance_pdf_viewer_fork: any

Android #

No permissions required. Uses application cache directory.

iOS #

No permissions required.

How-to: #

Load PDF

// Load from assets
PDFDocument doc = await PDFDocument.fromAsset('assets/test.pdf');
// Load from URL
PDFDocument doc = await PDFDocument.fromURL('');

// Load from file
File file  = File('...');
PDFDocument doc = await PDFDocument.fromFile(file);

Load pages

// Load specific page
PDFPage pageOne = await doc.get(page: _number);

Pre-built viewer

Use the pre-built PDF Viewer

  Widget build(BuildContext context) {
        appBar: AppBar(
          title: Text('Example'),
        body: Center(
        child: _isLoading
            ? Center(child: CircularProgressIndicator())
            : PDFViewer(document: document)),

This code produces the following view:

Demo Screenshot 1


  • Allow password-protected files

Third-party packages used

Name Description
path_provider A Flutter plugin for finding commonly used locations on the filesystem. Supports iOS and Android.
flutter_cache_manager A CacheManager to download and cache files in the cache directory of the app. Various settings on how long to keep a file can be changed.
numberpicker NumberPicker is a custom widget designed for choosing an integer or decimal number by scrolling spinners.
pub points


unverified uploader

A flutter plugin for handling PDF files. Works on both Android & iOS

Repository (GitHub)
View/report issues


API reference


BSD-3-Clause (LICENSE)


flutter, flutter_cache_manager, numberpicker, path_provider


Packages that depend on advance_pdf_viewer_fork