About this plugin
Quick Download Button lets you add professional download buttons anywhere on your WordPress site with minimal effort. Whether you are sharing PDFs, music, software, videos, or archives, every aspect of the button — style, colour, icon, countdown, and access rules — is controlled from a clean settings panel or a single shortcode.
Seven button styles
- Large — full-width panel with prominent icon area
- Mid — compact horizontal layout
- Small — minimal inline style
- Basic — clean, no-frills button
- Pill — modern rounded pill shape
- Card — elevated card with a panel background
- Ghost — outlined transparent style
Countdown timer and popup modal
Set a wait time in seconds before the download starts. During the countdown an animated spinner and optional message keep the visitor informed.
Add a popup modal to display any content while the countdown runs — AdSense, banner ads, custom HTML, shortcodes, or any other embed code. You control whether the visitor can dismiss the popup early or whether it stays until the download fires automatically.
Full feature list
- Works with both the Gutenberg block editor and the Classic Editor via shortcode
- Button Row block and [quick_download_button_group] shortcode — place multiple buttons side by side with gap, alignment, and stack-on-mobile controls
- Countdown timer — configurable wait time in seconds with a custom message
- Popup modal during countdown — show ads or custom HTML/shortcodes while the timer runs; optionally prevent dismissal until the download starts
- File size display — auto-calculated from the WordPress uploads folder, or enter any text manually (works with external URLs too)
- File type icon — automatically detected for common extensions
- Custom download icons — choose from 10 built-in icons or supply your own SVG
- Custom file size icons — same built-in set or custom SVG
- Icon position — left or right of the button label
- Access control — restrict downloads to logged-in users or specific roles
- External URL support — link to files hosted anywhere
- Hidden download links — the real file URL is never exposed in the page source
- Force download — bypasses the browser’s open-in-tab behaviour for supported file types
- Open in new tab or same window
- Custom button colour, font colour, border, border-radius, padding, and alignment
- Panel colour for Card, Pill, and Ghost styles
- Multisite compatible
- Optimised loading — CSS and JS only enqueue on pages that contain a download button
Supported file types for automatic icon display:
pdf, `mp3`, `mov`, `zip`, `txt`, `doc`, `xml`, `mp4`, `ppt`, `htm`, `html`, `ps`, `tex`, `csv`, `xlsx`, `pptx`, `js`, `css`, `php`, and common images (`png`, `gif`, `jpg`, `jpeg`, `bmp`).
Developer-friendly
The plugin exposes several action and filter hooks so add-on plugins can extend it without editing core files:
- qdb_editor_localize_data — add data to the Gutenberg editor script
- qdb_localize_script_data — add data to the frontend script
- qdb_shortcode_atts — modify parsed shortcode attributes
- qdb_user_can_access — override or extend the access check
- qdb_button_data_atts — inject extra data-* attributes onto the button element
- qdb_shortcode_output — filter the final button HTML before output
Basic Usage
Gutenberg Block
- Open the post or page editor and click the Add Block (+) icon.
- Search for Download Button (listed under the Media category).
- Click the block to set the button title, then click the upload icon to select or upload your file.
- Configure colours, countdown, file size, access control, and popup in the block settings sidebar.
Shortcode — minimal
pdf"]
Shortcode — external file in a new tab
zip" open_new_window="true"]
Shortcode — countdown with wait message
"]
Shortcode — popup modal during countdown
The popup content goes between the opening and closing shortcode tags. It can include HTML, shortcodes, or ad embed code.
</p>[/quick_download_button]
To prevent the visitor from closing the popup before the download starts:
zip" wait="15" popup_closable="0"]Ad or message here[/quick_download_button]
Shortcode — button group (multiple buttons in a row)
zip"] [/quick_download_button_group]<h3>More Shortcode Examples</h3>
Auto-calculate file size (file must be in your WordPress uploads folder)
pdf"]
Manual file size (works with any URL, including external)
zip"]
Hide the file extension icon
pdf"]
Show file extension icon and text label
pdf"]
Change button style
zip"]
Available values: large, mid, small, basic, pill, card, ghost
Custom colours
zip"]
Custom border
zip"]
Change icon colour (dark/light)
zip"]
Place icon on the right
zip"]
Restrict to logged-in users
zip"]
Restrict to a specific role
zip"]
Countdown with file size and message
zip"]
Button alignment
zip"]
Stacked button group, mobile-friendly
pdf"]');<h3>Shortcode Attributes Reference</h3>
[quick_download_button]
Attribute
Description
Default
Example value
`title`
Button label text
`”Download”`
`”Download Now”`
`url`
URL of a file in your WordPress uploads folder
—
pdf”`
`url_external`
URL of a file hosted outside WordPress
—
zip”`
`file_size`
`”1″` auto-detects size; any other value is displayed as-is
—
5 MB”`
`extension`
Show (`”1″`) or hide (`”0″`) the file type icon
`”1″`
`”0″`
`extension_text`
Also show the extension as text next to the icon
`”0″`
`”1″`
`open_new_window`
Open link in a new tab
`”false”`
`”true”`
`wait`
Seconds before the download starts
`0`
`”15″`
`msg`
Message shown during the countdown
`”Please wait…”`
`”Loading…”`
`button_type`
Button style
`”large”`
`large` / `mid` / `small` / `basic` / `pill` / `card` / `ghost`
`color_bg`
Button background colour
—
`”#ffc107″`
`panel_color`
Panel/card background colour (pill, card, ghost styles)
—
`”#f0f8ff”`
`color_font`
Button text colour
—
`”#ffffff”`
`color_icon_dark`
Use dark icon (`”true”`) or light icon (`”false”`)
`”true”`
`”false”`
`icon_id`
Built-in download icon
`”default”`
`default` / `cloud` / `circle` / `file-dl` / `inbox` / `save` / `bolt` / `folder` / `archive` / `info` / `chip`
`file_size_icon_id`
Built-in file size icon
`”folder”`
same set as `icon_id`
`icon_position`
Icon side of the button label
`”left”`
`”right”`
`border_width`
Border thickness in pixels
—
`”2″`
`border_style`
CSS border style
—
`”solid”`
`border_color`
Border colour
—
`”#333333″`
`border_radius`
Corner rounding in pixels
—
`”9″`
`align`
Button alignment on the page
—
`left` / `center` / `right`
`padding`
Vertical padding in pixels
—
`”12″`
`user_must_be`
Restrict access by role or login
—
`”loggedin”` / `”subscriber”`
`validate_msg`
Error message shown when access is denied
—
”`
`popup_closable`
Allow (`”1″`) or prevent (`”0″`) dismissing the popup before countdown ends
—
`”1″`
The popup_content is passed as enclosed shortcode content (between the opening and closing tags), not as an attribute. This allows unrestricted HTML, ad code, and nested shortcodes.
[quick_download_button_group]
Attribute
Description
Default
Example value
`layout`
`”horizontal”` (side by side) or `”stack”` (column)
`”horizontal”`
`”stack”`
`stack_on_mobile`
Automatically stack buttons vertically on small screens
`”true”`
`”false”`
`alignment`
Justify the buttons within the row
`”left”`
`left` / `center` / `right`
`gap`
Gap between buttons in pixels
`”12″`
`”20″`
Donations
If Quick Download Button saves you time and you’d like to support its development, buy me a coffee. Thank you!
Documentation & Source Code
To report issues or contribute, visit the GitHub repository.