Picture Uploader Always Converts to JPEG (Which is Great) - But how's it work?

MY QUESTION: Do you know how a Picture Uploader image is auto-converting to JPEG? And can I count on it to be reliable?

Users upload image in any file format, like PNG or HEIF (iPhone’s type), and the image is emailed via Postmark API and auto converted to JPEG as an attachment.

I want the image to auto-convert to JPEG, but since I don’t understand how it’s happening I’m not sure it’s reliable.

I checked with Postmark support to see if they were doing the auto-convert, they said no. So it must be happening between bubble or AWS. See the below API and take note of the “ContentType”: “image/jpeg”

“From”: “sample@email.com”,
“To”: “sample@email.com”,
“Cc”: “sample@email.com”,
“Bcc”: “sample@email.com”,
“Subject”: “Sample Email”,
“TextBody”: “Sample text of an email body.”,
“Attachments”: [
“Name”: “test.jpeg”,
“Content”: “<the file uploaded in bubble’s picture uploader>”,
“ContentType”: “image/jpeg”

You can upload a PNG and it will auto convert to JPEG as the attachment to the email. But how?

Update: I reached out to bubble support - they confirmed that the image file format is retained. In short, Bubble is not converting the image to JPEG and Postmark is not converting the image to JPEG.

So how is my Picture Uploader image converting to JPEG?

Not related directly to your inquiry, and perhaps you’re already aware, but just in case…

If you’re allowing users to upload images through your Bubble site, then you should also be managing those uploads appropriately, or else you’re potentially squandering your [rather pricey] Bubble storage and possibly making an administrative nightmare for yourself.

Let me know if you need more info.

THANKS @sudsy - I’m not aware of how to manage appropriately. It’s a new feature that could cause hundreds of new image uploads from mobile per week. I’m very interested to hear more. I would hate to have an administrative nightmare :grimacing: and high costs.

Anything specific I should consider or read?

In that case, you’ll definitely want to learn more about managing your uploads and Bubble storage. This thread might be a good place to start.

My Upload Buddy plugin was developed to help address the storage capacity issue, but one must also smartly manage uploads, including deleting files that are no longer needed. Basically, any uploaded file takes up Bubble storage until explicitly deleted.

@sudsy I appreciate it. I read through a bunch of your older posts on the topic (good tips BTW), including the one you linked above.

So storage costs are $10 per 10 GB per month. It seems your app will help minimize explosive costs.

What did you mean by administrative nightmare? Did you mean it’s a pain to find and delete orphaned images?

Well, it can be if you’re not aware of and/or don’t design your app properly from the outset. Sounds like you did your research and due diligence, and you’re at least aware of the potential issue and have given it some thought. :+1:

1 Like

Hello Brad, did you find a solution to changing png or jpg to jpeg on bubble?