I’m using Google Docs viewer to display PDF files on my website. Everything works fine except there’s a toolbar button that lets users open the PDF in a new window and download it. I want to keep the viewing functionality but remove the download option completely. Is there a way to hide or disable that specific toolbar button in Google Docs viewer? I tried looking through the documentation but couldn’t find any parameters to control this. If Google viewer doesn’t support this feature, can anyone recommend alternative PDF viewers that offer view-only mode without download capabilities? I need something that works reliably across different browsers and doesn’t require users to install plugins.
unfortuately google docs viewer is pretty limited on customizing the toolbar. I tried messing with it for months but had to move on. maybe try embedding it with an iframe and using css to hide that download button. converting PDFs to images on the server side is an option, but it can be a pain for multi-page docs.
Been dealing with this exact issue for corporate document sharing and honestly the Google viewer limitations are frustrating. What worked for me was switching to ViewerJS - it handles PDFs through HTML5 without exposing direct download links. It renders documents in a sandbox that makes it harder for casual users to grab the original file. Setup’s straightforward and performance has been solid across Chrome, Firefox, and Safari. I also explored server-side PDF protection using tools like PDFtk to strip metadata and add viewing restrictions before serving them. This adds some overhead but gives you better control over how documents behave if someone manages to save them.
Nope, Google Docs viewer doesn’t let you disable downloads - that’s intentional since Google sees it as essential for accessibility. I hit this same wall building a client portal last year and had to find something else. Tested a bunch of options and landed on PDF.js - way more control over the interface. You can strip out download buttons and kill right-click menus easily. It’s open source, works across all browsers, and runs pure JavaScript so no plugins needed. You could also try PDFObject with CSS to hide toolbar stuff, but that’s hit-or-miss depending on which browser PDF viewer people use. PDF.js took me half a day to set up right, but it’s been bulletproof ever since.