PDF Viewer – Drop, Reference, Open
Tested on Windows 11 only. macOS, Linux, Editor outside Play mode: opens the system PDF app. Not tested on macOS or Linux. ... Limitations ... Forms cannot be filled in.
by luanrobs
Price History +
Show a PDF in your app without worrying about anything else.
I started this plugin because I needed it. I was building an air suspension control app in Unity and had to show the suspension's manual, a PDF, inside the app.
So it works the way I wanted: drop the PDF file into your project, reference it in your script or straight in a Unity Button, and call Open(). On Android it opens in a native full-screen viewer; on Windows, in a full-screen viewer inside your app. It works in games too, although I had apps in mind.
Three ways to open a PDF, from the simplest:
- On Click (). Drag the PDF into a Button's On Click () list and pick PdfAsset > Open (). No component, no script.
- PDF Open Button. Add the component to a UI Button and assign the PDF.
- One line of code: manual.Open(); on a [SerializeField] PdfAsset field.
Key features
- PDFs are assets. Every .pdf is imported as a PdfAsset you can assign in the Inspector, with default viewer options per PDF.
- Native Android viewer with pinch and double-tap zoom, page indicator and toolbar.
- In-game Windows viewer for Windows 10/11 x64 builds and the Editor's Play mode: wheel, Ctrl + wheel zoom, drag, keyboard. No Canvas or EventSystem needed.
- Same options on both: title, start page, scroll direction, night mode, toolbar, page indicator, zoom.
- Events (Opened, PageChanged, Closed, Error) on the main thread.
- Several sources: PdfAsset, file path, StreamingAssets, URL or bytes.
- Pages as textures: PdfDocument renders any page into a Texture2D; PDF Page Image shows one page in a RawImage without code.
- No third-party dependencies and no setup. No AndroidX, no Gradle templates, no permissions. Full C#, Java and C++ source included.
- Eight sample scenes and a full manual (Markdown and PDF).
Supported platforms
- Android API 23+ (API 25+ with Unity 6000.3): native viewer, all options and events, page rendering.
- Windows 10/11 x64 (player and Editor Play mode): in-game viewer, all options and events, page rendering. Tested on Windows 11 only.
- macOS, Linux, Editor outside Play mode: opens the system PDF app. Not tested on macOS or Linux.
- iOS and WebGL: not supported in this version. Do not buy this version for iOS.
Requirements: Unity 6000.0.84f1 or newer (tested with 6000.0.84f1 and 6000.3.12f1). The components and demo scenes use uGUI.
What was tested: 506 EditMode tests on Unity 6000.3.12f1 and, from a package tarball, in new projects on 6000.0.84f1 and 6000.3.12f1; Windows 11 x64 Mono players; Android emulators (API 23, 24, 26, 29, 36); a Samsung Galaxy S23 (Android 16). Not tested: Windows 10, IL2CPP Windows players, HDRP, Android API 25, 27, 28 and 30-35. The manual lists every run.
Limitations
- Full-screen viewer, one at a time. No text selection, links or search; pages are shown as images.
- Password-protected PDFs are not supported. Forms cannot be filled in.
- Android: Unity is paused while the viewer is on screen; events arrive when the game resumes. On API 23-25, rotated or cropped pages are drawn without rotation or cropping.
- Windows: your game keeps running under the viewer; uGUI input is blocked, input your scripts read directly is not.
- Page textures: up to 4096 px per side, no mipmaps, not readable.
Third-party notice. Asset uses Nunito and Fira Code (font subsets embedded in the sample PDFs and the PDF manual) under the SIL Open Font License 1.1, and its Windows DLL contains code from the Microsoft Visual C++ runtime (under the license terms of Microsoft Visual Studio) and from C++/WinRT (MIT License); see Third-Party Notices.txt in the package.
Supported by a solo developer. If something does not work for you, email me before leaving a review and I will do my best to fix it.
Product page, manual and changelog: https://luanrobs.com/pdf-viewer/
Support: luanrobs@gmail.com
AI disclosure. This package was developed with the assistance of generative AI tools. The code, the tests, the documentation and the sample content of this package were generated with an AI tool (Claude, through Claude Code) under my direction, then run and tested as listed under "What was tested".