Pdf file in google drive convert base64

Good night friends!

I have a problem that maybe someone can help me with.

I need to take a .pdf file that is stored on my Google Drive and convert it to base64 so that I can send it via WhatsApp.

I already looked here on the forum and didn’t find anything similar.

I would appreciate it if you could help me.

Thanks

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Hi @sawagner, welcome to the community!

To get the file content as base64 you can use the “Keep As Base64” option of the Convert to/from binary data node:

Example workflow:

Edit: unfortunately the forum uses an older n8n instance which can’t properly render the current version of the aforementioned node. So the preview might appear broken until this instance is updated, but the approach shown above should still work of course.

n8n will then provide the base64 string representation of your file which you can use in subsequent nodes as needed.

Hope this helps!

2 Likes

Thanks!!!

thank you very much

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.