Skip to main content
Best answer

decode base64 encoded pdf data and attach the pdf in Zapier

  • April 12, 2023
  • 1 reply
  • 463 views

buckoh9

This is similar to How to send decode base64 encoded pdf data and attach the pdf in Zapier? | Zapier Community but there was never a solution provided for this.

We have a zap which catches a webhook that has a data element for a PDF encoded in base64.

We want to convert that to an actual PDF file so it can be attached in an email sent through Gmail

Any ideas on how to effectuate?  

Currently, we just get a .txt attachment with the base64 data in it.

Best answer by SamB

Just spotted this one had no replies, so wanted to share an answer here. I recently put together a guide on how to convert a base64 encoded string into a PDF file with the Zapier SDK:

The approach decodes and uploads the file directly to Google Drive, and once uploaded the file can be passed along to a Gmail action to be attached to an email.

Hopefully this helps anyone coming across this in the future! 🤞

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

1 reply

SamB
Community Manager
Forum|alt.badge.img+11
  • Community Manager
  • Answer
  • July 9, 2026

Just spotted this one had no replies, so wanted to share an answer here. I recently put together a guide on how to convert a base64 encoded string into a PDF file with the Zapier SDK:

The approach decodes and uploads the file directly to Google Drive, and once uploaded the file can be passed along to a Gmail action to be attached to an email.

Hopefully this helps anyone coming across this in the future! 🤞