-1

I see many posts that it is not possible to render base64 image as pdf in visualforce page, is it still possible ? This image is coming from another system and I do not want to store in sf as an attachment instead directly render as pdf.

<apex:page renderAs="pdf">
    <apex:image value="data:image/png;base64,iVBORw...." alt="" />
</apex:page>

2 Answers 2

2

This will never work until/unless the underlying PDF rendering engine, Flying Saucer, is updated to included support for this feature. As far as I'm aware, there's no plans to include a more capable PDF engine. We have two rendering systems available, pdf and advanced_pdf, neither of which support data URL images.

0

Visualforce PDF rendering doesn’t support images encoded in the data: URI scheme format. It is one of the limitations of the Visualforce PDF rendering.

enter image description here

Visualforce Developer Guide: https://developer.salesforce.com/docs/atlas.en-us.pages.meta/pages/pages_output_pdf_considerations.htm

IdeaExchange post: https://ideas.salesforce.com/s/idea/a0B8W00000GdhkhUAB/support-inline-data-uri-scheme-images-for-pdf-output-in-visualforce-pages

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .