Storing Base64 String

I need to store video’s encoded in Base64 strings. However, I’m running into issues where the string is often too long for Bubble to store. I get an error “Text too long for this field” and in general my database is just extremely slow with these very long text fields.

Is there a better way to store Base64 strings that I don’t know about?

Given the nature of Base64 its just not going to be a good fit for large files.

What is the end result you’re looking for? What is the need for Base64?

1 Like

Why? Why do you need to store them locally? I’d highly recommend using a cloud service to host/serve your media content I’d it’s important

1 Like

You can’t store large Base64 like that in the database, see the hard limits here: Hard limits - Bubble Docs

Text fields

A single text field saved in the database has a hard limit of 10 million characters . Keep in mind that this includes characters like spaces and BBCode/HTML formatting.

Thing size

The total size of data stored in one thing has a hard limit of 20 MB . This refers to data stored in the thing itself, and not associated data such as files and images.

Proper file storage like using Bubble storage or external S3 storage is the way to go. Streaming heavy video you would want a CDN in front of it so they cache videos near your users.