mozilla/pdf.js
View on GitHub ↗ ★ 54,076 JavaScript
PDF Reader in JavaScript
67 mentions on Hacker News by 60 people: 4 stories, 63 comments · first 2012-01-27 · latest 2026-10-30
20082026
-
▲ 2
PDF Reader in JavaScriptstory by saikatsg · 2026-10-30 · 0 comments
-
…https://github.com/mermaid-js/mermaid https://github.com/moment/moment https://github.com/mozilla/pdf.js https://github.com/pixijs/pixijs https://github.com/mapbox/earcut https://github.com/primus/eventemitter3 https://github.com
comment by CMay · 2025-09-20 · in Less is safer: Reducing the risk of supply chain attacks -
…any case, Hebrew is handled differently from other RTL languages, hence this bug report in PDF.js: https://github.com/mozilla/pdf.js/issues/20097 Almost certainly something a smaller team would have never caught, given that a team with a…
comment by zdragnar · 2025-08-15 · in Show HN: I built a free alternative to Adobe Acrobat PDF viewer -
I'm curious to know why you built this when the Mozilla PDF viewer exists: https://github.com/mozilla/pdf.js Not criticizing because there's lots of reason to build things that exist, just curious.
comment by wewewedxfgdf · 2025-08-14 · in Show HN: I built a free alternative to Adobe Acrobat PDF viewer -
https://github.com/mozilla/pdf.js#readme (Apache 2)
comment by mdaniel · 2025-06-13 · in Show HN: Tritium – The Legal IDE in Rust -
Yes, pdf.js can do that: https://github.com/mozilla/pdf.js/blob/master/web/viewer.htm... . The purpose of my original comment was to simply say: there’s an existing implementation so if you’re building a pdf file viewer/editor, and you…
comment by rad_gruchalski · 2025-05-13 · in PDF to Text, a challenging problem -
▲ 2
Pdf.js: A Lightweight, Native PDF Reader Built in JavaScriptstory by CryptoPivotPro · 2024-08-15 · 0 comments
-
…enabled by default. The feature is still sitting as "planned for the future" in their PDF library: https://github.com/mozilla/pdf.js/issues/15843
comment by lights0123 · 2024-05-24 · in Show HN: You can now cut and paste from scanned documents in Firefox -
https://github.com/mozilla/pdf.js#online-demo
comment by haebom · 2023-12-12 · in Ask HN: Best PDF Viewer in Browser? -
…are actually an extension, just one built in as Firefox's default pdf viewer. It's called pdf.js https://github.com/mozilla/pdf.js/ You can actually use this pdf viewer in another browser like Chrome if you'd like, there's a demo URL on…
comment by chownie · 2023-10-28 · in Firefox 119 unleashes PDF prowess and Sync sorcery -
…/blog.chromium.org/2011/01/html-video-codec-support-i... [2]: https://github.com/chromium/pdfium [3]: https://github.com/mozilla/pdf.js
comment by Nathan2055 · 2023-07-19 · in Microsoft faces antitrust scrutiny from the EU over Teams, Office 365 -
They already have a pdf reader they could add with ease https://github.com/mozilla/pdf.js
comment by nazgulsenpai · 2022-12-26 · in Save web pages as PDF in Firefox for Android -
…might want to have a look at the documents used as test cases in other projects, such as pdf.js: https://github.com/mozilla/pdf.js/tree/master/test/pdfs
comment by fgeiger · 2022-11-18 · in Show HN: I am building a new Python library to read/write PDF files -
PDF.js does support decrypting password-protected documents on its own: https://github.com/mozilla/pdf.js/issues/7967
comment by commoner · 2022-08-22 · in React PDF Viewer -
…one in Chrome or similar. This is what PDF.js is... > PDF.js is built into version 19+ of Firefox. https://github.com/mozilla/pdf.js
comment by mcny · 2022-08-22 · in React PDF Viewer -
…I'm taking my shot with https://github.com/wailsapp/wails (webview2 supported on Windows) and https://github.com/mozilla/pdf.js for a PDF processing related use case. Wails because I imagine extensive Golang based services…
comment by ramoz · 2022-01-21 · in Ask HN: Anyone making a living building desktop applications? -
Firefox has included a viewer based on PDF.js since 2013: https://github.com/mozilla/pdf.js#online-demo No need to download to anything other than localstorage. There have been a half dozen vulnerabilities found in the Firefox extension…
comment by LeifCarrotson · 2022-01-14 · in The collapse of 1284 at Beauvais Cathedral [pdf] -
https://github.com/mozilla/pdf.js/issues/2750 It's because pdf.js does not print vector and instead is just printing canvas bitmaps. If they ever get the SVG backend working its will finally have good print quality without trying to get…
comment by SigmundA · 2021-10-17 · in Implementing form filling and accessibility in the Firefox PDF viewer -
…browser's own JS engine (but confined to a sandbox), and quickjs in other settings (say a website). https://github.com/mozilla/pdf.js/issues/12487 But I can't find Components.utils.Sandbox being referenced in the code on github. So maybe…
comment by est31 · 2021-04-19 · in Firefox 88.0 -
…with it (probably overkill, really) and I'm using Mozilla's pdf.js [1] to render documents. [1] https://github.com/mozilla/pdf.js
comment by heresjohnny · 2020-12-29 · in Show HN: Tuchu – Automatically highlight the important parts of a document -
…easier for you to contribute to the project by providing you with the lines you'd need to update: https://github.com/mozilla/pdf.js/blob/83e1bbea6e23db8744420... https://github.com/mozilla/pdf.js/blob/83e1bbea6e23db8744420...
comment by tarikozket · 2020-09-23 · in Embedded PDF viewer in Firefox 81 supports filling forms -
…easier for you to contribute to the project by providing you with the lines you'd need to update: https://github.com/mozilla/pdf.js/blob/83e1bbea6e23db8744420... https://github.com/mozilla/pdf.js/blob/83e1bbea6e23db8744420...
comment by tarikozket · 2020-09-22 · in Embedded PDF viewer in Firefox 81 supports filling forms -
Firefox PDF support is actually Javascript. https://github.com/mozilla/pdf.js
comment by Hamuko · 2020-09-22 · in Embedded PDF viewer in Firefox 81 supports filling forms -
…other than for the purpose of functioning as the core pdf viewer. But I am not that imaginative! https://github.com/mozilla/pdf.js/wiki/Frequently-Asked-Ques... https://en.wikipedia.org/wiki/PDF.js
comment by mapgrep · 2020-08-25 · in Firefox 80 -
…pdf form printing for quite a long time[1],instead of rolling a canvas screenshot hack. [1] https://github.com/mozilla/pdf.js/issues/7613
comment by phonon · 2020-04-03 · in Show HN: Pdf.js Express – PDF annotation, e-signatures, and form filling -
…moving away from their proprietary XFA format, with the introduction of their forms extension. [1] https://github.com/mozilla/pdf.js/issues/2373
comment by niknikson · 2020-04-02 · in Show HN: Pdf.js Express – PDF annotation, e-signatures, and form filling -
IIRC this is also how Firefox is doing it for its pdf.js print feature: https://github.com/mozilla/pdf.js/blob/master/web/pdf_print_... Which is why when you print a PDF from Firefox, it doesn't look very nice. But it's safer than sending…
comment by est31 · 2020-03-08 · in Dangerzone: Convert potentially dangerous PDFs, documents, or images to safe PDF -
Better to go upstream https://github.com/mozilla/pdf.js/issues
comment by phonon · 2019-06-24 · in Give Firefox a chance -
…https://opensource.google.com/projects/pdfium its native and fast. Firefox I think still uses https://github.com/mozilla/pdf.js which was not bad last time I used it, but it all javascript so performance isn't up to par with native. Also…
comment by SigmundA · 2019-05-03 · in PDF Is the World's Most Important File Format -
…PDF generation is done with some script like https://github.com/mrrio/jspdf and then rendered with https://github.com/mozilla/pdf.js :)
comment by cheeaun · 2019-03-26 · in Convert Markdown to PDF only using browser -
…dependencies. Since it's such a quickly evolving project, I wondered where form support is up to. https://github.com/mozilla/pdf.js/issues/7613 Form support is not complete. Seems like it required quite a rewrite to get the foundation in a…
comment by throwaway12iii · 2018-12-13 · in 50 CVEs in 50 Days: Fuzzing Adobe Reader -
…next page, and p/k to go to previous page. Works quite nicely for flipping through PDF slides. [0]: https://github.com/mozilla/pdf.js/wiki/Frequently-Asked-Ques...
comment by aban · 2018-08-07 · in Categorifying cardinal arithmetic [pdf] -
…Firefox itself use pdf.js for PDF rendering? The FAQ says it's been baked into Firefox since v19: https://github.com/mozilla/pdf.js/wiki/Frequently-Asked-Ques...
comment by koolba · 2018-05-03 · in A standards-based PDF viewer created using Electron and Pdf.js -
…PDFViewerApplication.preferences.set('renderer', 'svg');` in the console, and reload the page/viewer: https://github.com/mozilla/pdf.js/pull/8564
comment by pettou · 2017-06-27 · in SVG backend for PDF.js -
You might be able to tweak this pdf.js example to dump out its canvas element after it renders. https://github.com/mozilla/pdf.js/blob/master/examples/learn...
comment by jevinskie · 2017-04-12 · in Chrome 59 has cross-platform headless support -
Javascript-based PDF renderers exist already - Firefox uses one by default. https://github.com/mozilla/pdf.js/
comment by detaro · 2017-04-07 · in Show HN: Resumegen – A single-page LaTeX resume generator -
▲ 1
Tell HN: Mozilla's pdf.js needs help with automated testing (2016)story by collinmanderson · 2017-03-03 · 0 comments
-
…of PDFs every day ...has anyone from Mozilla ever talked to ACORD (or even knows who they are?) [1] https://github.com/mozilla/pdf.js/issues/7613 [2] http://www.codeproject.com/Articles/466362/Blend-PDF-with-HT...…
comment by phonon · 2016-10-01 · in Firefox: Announcing Project Mortar -
How many people are working on PDF.js that are paid by Mozilla? https://github.com/mozilla/pdf.js/graphs/contributors looks like there are only 2 main contributors (i.e. maintainers, in the sense of continuously and ongoing committing for…
comment by nachtigall · 2016-09-30 · in Firefox: Announcing Project Mortar -
https://www.adobe.com/uk/epaper/tips/acr5reflow/ https://github.com/mozilla/pdf.js/issues/4816
comment by based2 · 2016-08-14 · in Guido van Rossum: “PDF Must Die.” (2014) -
…would be http://web.mit.edu/~simsong/www/ugh.pdf#page=177 For pdf.js (used by Firefox), refer to https://github.com/mozilla/pdf.js/wiki/Viewer-options If using Adobe Reader, refer https://www.adobe.com/content/dam/Adobe/en/devnet/acrobat/pd…
comment by 0xmohit · 2016-07-07 · in Xplain – Explaining X11 for the rest of us -
…we will need to add PDF support into Photopea in the future. Luckily, there already exists pdf.js https://github.com/mozilla/pdf.js/ :)
comment by IvanK_net · 2016-03-04 · in Fun Photoshop File Format Facts -
Yeah, and that feature was only used in the Firefox deployment of pdf.js. https://github.com/mozilla/pdf.js/commit/4f3f983a214867011dd... Not sure who's to blame, but like he said, there was no vulnerability in the web version.
comment by yAnonymous · 2015-08-12 · in Firefox Under Fire: Anatomy of latest 0-day attack -
I believe the upstream pdf.js fixed this already, https://github.com/mozilla/pdf.js/ .
comment by LaSombra · 2015-08-07 · in Same origin violation and local file stealing via PDF reader -
Checkout the pdfjs test suite, if you want to try it: https://github.com/mozilla/pdf.js/tree/master/test/pdfs
comment by ushi · 2015-03-17 · in PDF Viewing -
The Firefox PDF viewer (pdf.js) can be used in any browser from any website. https://github.com/mozilla/pdf.js See a demo: http://mozilla.github.io/pdf.js/web/viewer.html
comment by logn · 2015-02-20 · in Ask HN: SaaS solution to provide easy and nice PDF embedding in a web page? -
…past it to get to the add-on. PDF.js uses this approach actually. See "Development version" at https://github.com/mozilla/pdf.js/ as an example.
comment by msujaws · 2014-11-25 · in Mozilla’s Add-on Policy Is Hostile to Open Source -
If anyone wants to report an issue: https://github.com/mozilla/pdf.js/issues
comment by voltagex_ · 2014-10-31 · in Excuse Me Sir, Would You Like to Buy a Kilo of Isopropyl Bromide? (1977) [pdf] -
It appears to be a bug in pdf.js (or the PDF format itself): https://github.com/mozilla/pdf.js/issues/5064 As somebody else mentioned, you can use the arrow/triangle to display the regular viewer toolbar, and zoom out. This is obviously…
comment by joepie91_ · 2014-07-19 · in Identifying backdoors, attack points, and surveillance mechanisms in iOS devices -
…v1.0.277 is a pre-release, so this will probably be in the next release or the one after that. ( https://github.com/mozilla/pdf.js/releases ) I have recently switched my project from v0.8.1013 (from feb 2014) to v1.0.68 and rendering times…
comment by jeroen · 2014-06-16 · in An even slimmer pdf.js