<img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=442498563201411&amp;ev=PageView&amp;noscript=1">

WordPress: Charging for Downloadable Content using the LaterPay Plugin

Topics: WordPress · Downloads
Experience Level: Intermediate
June 29, 2020 · 7 min read







Tip: Did you know that LaterPay has two WordPress plugins?
Click here if you're looking for the Revenue Generator plugin.




Now that you have your LaterPay Plugin set up, we want to introduce you to one of our more advanced features  the ability to charge for downloadable content. Although this is one of our more “advanced" features, it is still quite simple to set up thanks to WordPress blocks & shortcodes.


Using Blocks

The simplest way to monetize downloadable content in the WordPress Editor is using WordPress's block functionality. In the Editor, simply:LaterPayWordPressBlocks

  • Click to add a new block
  • Scroll down & expand the LaterPay Blocks section or search for the following block
  • Select "LaterPay Premium Download Box"

Once you have added the block, configure the settings as desired in the block settings menu displayed along the right side of your screen. Once these are configured, simply update or publish your article to make your changes live!


Using the ShortCode


A quick refresher - according to WordPress.com, a shortcode is a WordPress-specific code that lets you do nifty things with very little effort. Shortcodes can embed files or create objects that would normally require lots of complicated, ugly code in just one line. In other words, ‘shortcode’ = ‘shortcut.’

The [laterpay_premium_download] shortcode allows you to quickly and easily charge for downloadable content. Here’s how:

  1. Ensure that you have the "Media" content type enabled on the LaterPay Paywall tab
  2. Upload the downloadable content to the WordPress Media section
  3. Open the content from within the WordPress Media section
  4. In the URL there should be text that reads something like “item=138” – take note of that item number
  5. Click “View attachment page” and then click “Edit” to edit that page. Once you are on the Edit screen – which will look very similar to the Edit Post page – you can set an “Individual Price” which will be the price that a reader must pay to access this piece of content
  6. Set-up is complete! Now we just need to display the download link on the page. This is done by placing a [ laterpay_premium_download ] shortcode in your post wherever you would like the download widget to appear.

Before we dive into the details, here is an example of what this could look like and the code used to generate it:

Downloadable Content Example: The state of paid Content $2.99[laterpay_premium_download target_post_id="138"
heading_text="The State of Paid Content"
description_text="The ad model is broken, the 'pivot to readers' is incomplete, and conditions are right for experimentation."


TIP: If you copy and paste the above shortcode as a starting point, be sure to remove the extra line breaks.


Shortcode Details

Now that you have seen an example, here are details on all of the different options available. It’s worth noting that the only thing that is required is the target_post_id, which lets LaterPay know what you want to sell. Everything else is completely optional.




target_post_id The WordPress id of the page that contains the paid content REQUIRED; see step 4 above for more details
heading_text The text that should be displayed as a heading in the teaser box; restricted to one line Optional
description_text Text that provides additional information on the paid content; restricted to a maximum of three lines Optional
content_type Choose between ‘text’, ‘music’, ‘video’, ‘gallery’, ‘file’, or ‘link’ to display the corresponding teaser image (examples below) Optional; will be overwritten if a teaser_image_path is provided
teaser_image_path Path to an image that should be used instead of the default LaterPay teaser image

Optional; detailed instructions below


content_type & teaser_image_path examples


image to display

content_type=”text” content_type: text
content_type=”music” content_type: music
content_type=”video” content_type: video
content_type=”gallery” content_type: gallery
(default if both content_type & teaser_image_path are left blank, the image will default to ‘file’)
content_type: file

To add a custom image as is done in the provided example:

  1. Upload the image you would like to appear in the background
  2. In the Media Library, click on this image
  3. Copy the media URL
  4. In your short code paste the media URL inside double quotes after “teaser_image_path=”
  5. Erase the first portion of the URL so that what is remaining in the short code starts with “/wp=content/uploads/…”

For example: if the URL for the image in the example above were


and the corresponding short code parameter is



If your [laterpay_premium_download] shortcode is not working, use the WordPress HTML tool to ensure that there is no HTML or line breaks inside your shortcode. If either of these are into your shortcode, simply remove them; that should do the trick!


Next up, let’s take a look at another example - creating a paid video or podcast!


Further Reading