Open PDF Links Directly in Glide App Without Downloading

Hi everyone,

In my Glide app, I currently have a link to a PDF file (as shown in the screenshot). At the moment, clicking the link prompts the file to download.

Is there a way to modify this behavior so that the PDF opens directly in a window within the app instead of being downloaded?

Your insights and suggestions would be greatly appreciated!

Thanks in advance!

You can use a web embed that displays the document’s preview.

Have you tried another OS to see if it behaves the same way?

It also might relate to the website that is storing the file. Is it possible for you to upload that file to Glide storage?

Hi, but the thing is I can only download or preview if I enter credentials

Hi, I don’t quiet get, what do you mean by another OS? and Yes I cannot upload the files to glide storage as they are on a separate website it requires credentials to be entered first then pdf are downloaded, now I want to know if there is any way the pdfs are directly open in glide app

I mean say if you’re using it on desktop, have you tried the app on iOS/Android to see if it works differently?

Hi I tried, but It is working on Android, don’t have and IOS though

How/where are you storing these documents? If the preview function is critical to your application, you may consider storing them in Glide or somewhere not behind a login potentially. One option could be Amazon S3, using signed URLs to preview the document.

If the external service you are using requires login, I’m not sure you can work around that limitations without building some federated login capability which is a larger undertaking and doesn’t always play well with Glide.

1 Like

Make a new workflow that opens a new screen, and inside the new screen, use the web embedded with the PDF as the source; the PDF link must be public, and remove the ?download if it has one.

The thing is, the documents are stored on totally different server I just have their url and we just need to view them but it is ok even if it get downloaded in glide but we have to log in in order to view the pdf to that server where document are stored, but I got to know in other similar post that we cannot do “the log in” thing in glide

The thing is, the documents are stored on totally different server I just have their url and we just need to view them but it is ok even if it get downloaded in glide but we have to log in in order to view the pdf to that server where document are stored, but I got to know in other similar post that we cannot do “the log in” thing in glide

Many people compare issues with PDFs not being readable on mobile and desktop devices. What you need to understand is that opening a PDF requires a PDF reader. Many gadgets do not have a built-in PDF reader in their browser, and that’s the cause of the problem.
However, if your file is public, you can wrap it with Google’s free PDF viewer. Try replacing {PDFLINK} with your file’s URL. Good luck!

https://docs.google.com/viewer?embedded=true&url={PDFLINK}

Thank you for your suggestion, but issue here is to have some way to view PDF even it requires log in Glide App, even if it requires to log in before viewing the pdf

I haven’t tried opening a PDF that requires login before. However, you could try embedding the URL into a WebView component. A WebView acts like a window to the outside world — hopefully, it will prompt you with a login method, provided that Glide doesn’t restrict it or you’ve adjusted the original file’s permissions.

1 Like

Yes, I am doing exactly as you said, but it is not working, could you tell me if there is something wrong with what I am doing?

Not all sites allow themselves to be embedded in an iframe. You’re probably going to need to use the Open Link action to open it externally from the app.

1 Like

Yes, but’s that not required functionality

Vac_Invoice column is set to text instead of URL.

and this is what I use for google docs, check the link but in my case its a google document not a pdf
https://docs.google.com/document/d/YOUR-GOOGLE-DOCUMENT-ID/preview
And it’s showing very nicely:

Yes, it is text column, because inside database it is text and there is text for some reason I cannot make changes to databases here I am retrieving my column using look up can I some how convert it to url in glide , simply my question is can we do typecasting in glide in my case for converting the type of url column from text to url