Hacking Bubble: The Download Hack

Learn how to let users download files from your Bubble app.

Ryan Roberts
October 24, 2016 • 2 minute read
White download icon on a gray background.

Let’s say, you are making a cloud and/or sharing service. It would be disappointing to find out after putting in all of that work to make the app, you can’t have your users download an image from your website. At least it was for me, so if this very specific problem has occurred for you too, this article will explain how to make images download onto the user’s computer instead of doing this.

But can’t I just send the user to the file URL, wouldn't that download it for them, you ask?

Nope, probably. If this was any other kind of file, then most likely. We are talking about browsers here, so I can’t talk in absolutes. It’s difficult to assume a general behavior between all browsers as they can behave different from each other.

Okay, then what is probably the solution to this, you add?

This:

Let’s break this down. The <a> tag is for creating a link so we will need that to direct the page to the source image (or any file). The style=”” is a CSS element that you would use to style the button. href=”” is where you would enter the source file URL that the <a> tag will use. You can either copy and paste the static URL between the quotations if the file will not change, or add a dynamic element like I have. Finally, just type download after the href=”<link>”.

The addition of ‘download’ to the end of the href tag makes all of the difference, but then again, browsers, so I don’t know.

Just make an HTML element in Bubble and type this code in. You can change up the color hex, font-size, font-family, etc. Make it entirely how you want it to look. You can learn more about how to CSS in this Introduction to CSS.


Hacking Bubble is a series on how to make Bubble do things it probably wasn’t meant to do.

Don’t miss out on the latest Bubble content by signing up here.

Was this article useful? Do you have a better or different approach? Let me know!

Start building with a free account

Build your app on Bubble's Free plan. No need to upgrade until you're ready to launch your app.

Join building

LATEST STORIES

Two interface panels side by side, a purple prototype editor with a selected element and an undo icon, next to a polished white app dashboard with security and completion icons.

AI Prototype vs. Production-Ready App: A Complete 2026 Guide

Learn what separates an AI prototype from a production-ready app, what tends to break when real users arrive, and how to check your AI-built app before launch.

Bubble
December 04, 2026 • 10 minute read
A sparkle icon on a gradient square, centered within concentric glowing diamond outlines on a dark background.

9 Best AI App Builders for Regulated Industries in 2027

Compare nine AI app builders for regulated industries on BAAs, SOC 2 Type II reports, data residency, access controls, and AI change review, and see what your organization still has to configure before launch.

Bubble
December 04, 2026 • 12 minute read
A bar chart with ascending bars and an upward trend line, next to a sparkle icon on a dark blue background.

How to Make the Business Case for an AI App Builder

Learn how to build a business case for an AI app builder, then back it with a pilot that leadership and IT can approve.

Bubble
December 04, 2026 • 11 minute read
A central app screen connected to six data cards, with icons for database, list, and a completed task.

How to Add an MCP Server to Claude Code: 2026 Setup Guide

Learn how to add an MCP server to Claude Code, sign in, check that its tools load, and fix common connection errors. You'll also see how to use the same setup to build an app from Claude Code, VS Code, or ChatGPT.

Bubble
December 04, 2026 • 11 minute read

Root Cause Analysis (RCA): October 2026 Security Incident

November 20, 2026 • 5 minute read

What Can You Build on Bubble? 25 Examples to Inspire You

September 08, 2026 • 14 minute read

The Easiest Way to Build a Custom CRM With AI

September 01, 2026 • 20 minute read

What Is Bubble AI and How Does It Build Apps?

August 19, 2026 • 13 minute read

See How We Redesigned the Property Editor for Better Building

December 11, 2025 • 4 minute read

Build the next big thing with Bubble

Start building for free