MP3 Audio Player
Search for articles about the Audio Player and WordPress Theme

How to add Audio Preview in WordPress

Welcome to the documentation for the Audio Preview feature, a unique feature of MP3 Audio Player Pro WordPress Plugin. This tool is engineered not only to provide users with a sneak peek of the audio content, but also to manipulate the audio by outputting pre-roll or post-roll advertising or watermark to the audio. Whether you run an online music stores on WooCommerce, podcast platforms, or any audio-centric website, the Audio Preview protect and enhances content presentation and user interaction.

What is Audio Preview? #

Its main uses are:

  • Preview Content: Offers a short taste, helping listeners judge the audio’s relevance.
  • Advertising: It allows to add advertising before and/or after your original audio tracks.
  • Informed Purchasing Decisions: It assists buyers decide whether to purchase the full audio track or subscribe to your website.
  • Security Measure: Playing only a snippet aids in preventing unauthorized full-track downloads. Some may also include voiceovers or “sample” watermarks for added security.

For users with limited access (eg: logged-out visitor or restricted roles), they will hear the “preview” file on your site. But, if no audio preview is set, they’ll access the full, original track. Plus, for added control, you can choose to provide full track access for certain playlists or songs, adjustable per post.

What can I do with the audio previews? #

The Audio Preview feature in MP3 Audio Player Pro is highly customizable and offers a plethora of options to tailor audio snippets to your preference and requirement. Here are some of the key functionalities you can leverage:

1. Determine Access Control:

By default, guests (logged-out visitors) will receive audio previews. You can extend this functionality to specific user roles using the multicheck options provided.

2. Generate Audio with FFMPEG:

Say goodbye to manual audio editing. Our platform auto-generates audio previews from your full-length tracks. This feature not only streamlines the preview creation but is also a significant time-saver.

  • Fade In & Out: Set the fade-in and fade-out lengths (in seconds) to ensure smooth beginnings and endings for your audio track.
  • Audio Watermark: Introduce an audio watermark, which will be embedded every ~10 seconds during playback. This is useful for branding and anti-piracy measures.
  • Pre-roll and Post-roll Ads: Integrate short audio advertisements at the beginning (pre-roll) or end (post-roll) of your audio file.
  • Trimming Options: Choose the start point of your preview and determine its overall duration. This allows you to highlight specific segments of your audio.
  • Overwrite Existing Files?: Decide if you want to overwrite existing audio previews. Useful if you make regular updates or changes to your audio files.
  • Folder Output: Specify a designated folder where all the generated audio previews will be stored.
  • Bulk Generation & Removal: With a single click, generate audio preview files for all your tracks. If you ever need to, you can also remove all generated preview files in bulk.

3. Add your Own Audio Preview Files

For those who have specific audio tracks in mind for previews, there’s flexibility to manually add them. Whether it’s for guest visitors or particular user roles, you can seamlessly introduce these tailor-made previews for any track.

These options, combined with the main Audio Preview feature, offer an enhanced level of customization and control over how your audience interacts with your audio content. Whether you want to provide a sneak peek, include ads, or watermark your audio, MP3 Audio Player Pro has got you covered.

System Requirements: #

To effectively use the Audio Preview, there are some prerequisites:

  • MP3 Audio Player Pro – Business Plan: The feature is a part of the MP3 Audio Player Pro – Business Plan. Ensure you’re on this plan or consider upgrading.
  • FFMpeg Library (Optional for Automatic Generation): FFMpeg Library is pivotal for auto-generating audio previews, trimming, watermarking, and adding pre-roll or post-roll ads. If you have it installed and rightly configured, the system can automatically generate snippets from your audio files. Make sure that your server allows shell_exec() function.
  • VPS or Dedicated Hosting: FFMpeg’s requires a VPS (Virtual Private Server) or Dedicated Server. Make sure your website is hosted on a VPS or Dedicated server. We recommend Cloudways for the best hosting which includes ffmpeg by default.

How to install FFMPEG #

  1. We recommend using for web hosting as FFMpeg comes pre-installed. Otherwise, installing FFMPEG varies based on the server you are using. Kindly ask your hosting provider to install it for you.
  2. Once FFMPeg is installed, make sure your server allows shell_exec() function. This is the function we use to call the FFMpeg instance. You may have to enable it manually. If you use Cloudways, see this documentation.
  3. Raise max_execution_time and max_input_time to 900. If you use cloudways, see this documentation.

How to Generate Previews for every tracks on your website #

  1. Go to WP-Admin > MP3 Player > Settings > Audio Preview & Restrictions
  2. Enable Audio Preview.
  3. Reviews your settings
  4. Click Generate Files

* To make sure audio previews have generated, clear your website cache and test in an incognito window (without being connected to the WP Dashboard). Logged-out visitors always get the preview files – if generated.

How to Generate Previews for a specific playlist, track or episode #

  1. Make sure Audio Preview is enabled in WP-Admin > MP3 Player > Settings > Audio Preview & Restrictions
  2. Go to WP-Admin > MP3 Player and edit a post.
  3. Click Generate Preview Files for all tracks.
  4. If you want to generate audio preview for a specific track, click Generate Preview File on a specific tracks. See screenshot.
  5. Update your post.

* To make sure audio previews have generated, clear your website cache and test in an incognito window (without being connected to the WP Dashboard). Logged-out visitors always get the preview files – if generated.

How to Create Audio Previews for Selected Posts #

You can also generate audio previews for multiple posts that you manually select.

  1. Go to WP-Admin > Playlists (or Products)
  2. Select the post you want by clicking the checkbox
  3. In the Bulk Actions dropdown, select “Generate Audio Previews” and click “Apply”
  4. You will be redirected to the bulk generation tool.
  5. Review your settings and click Generate Files button.

How to Disable Previews for a specific playlist, track or episode. #

  1. Go to WP-Admin > MP3 Player and edit a post.
  2. If you wish to disable previews for all the tracks, use the ‘Audio Preview’ dropdown above your tracklists, and select Disable.
  3. If you wish to disable previews for a specific track, use the ‘Audio Preview’ dropdown located at each of your tracks and select Disable.

Remember: If No Preview File is set, we will serve the Full Track.

* To make sure audio previews have generated, clear your website cache and test in an incognito window (without being connected to the WP Dashboard). Logged-out visitors always get the preview files – if generated.


1. What is the Audio Preview feature in MP3 Audio Player Pro?

The Audio Preview feature allows users to listen to a short segment or “snippet” of a longer audio file. This provides listeners with a glimpse of the content without playing the entire track, useful for a quick assessment and informed decision-making.

2. How can Audio Preview benefit my online audio platform?

Using Audio Preview enhances user engagement by offering a taste of the content. It can aid in purchase decisions for potential buyers, and act as a protective measure against unauthorized full-track downloads.

3. Can I manually upload my own audio snippet for the Audio Preview?

Yes, if you prefer to use a specific segment or if FFMpeg isn’t set up on your server, you can manually upload your chosen audio preview file.

4. What is FFMpeg Library, and why might I need it?

FFMpeg Library is a tool for processing multimedia content. For the Audio Preview feature, it can auto-generate audio snippets, trim audio, add watermarks, and even insert pre or post-roll ads.

5. Do I need a specific hosting setup for using FFMpeg with MP3 Audio Player Pro?

FFMpeg is resource-intensive. It’s recommended to have a VPS (Virtual Private Server) or Dedicated Server if you plan on using FFMpeg for the Audio Preview feature.

6. What if I don’t set an audio preview for a track?

If no audio preview is set for a specific track, users will default to hearing the full track when they access it.

7. Is the Audio Preview feature available on all MP3 Audio Player Pro plans?

No, the Audio Preview feature is exclusive to the MP3 Audio Player Pro – Business Plan (or higher). Ensure you’re on this plan to access and use the feature.

8. Can I decide which tracks or playlists offer the full audio despite having an Audio Preview?

Yes, the Audio Preview feature allows granular control, letting you provide full track access for specific playlists or tracks. This can be adjusted for individual posts.

9. How does the Audio Preview feature deter unauthorized downloads?

By offering just a short snippet rather than the full track, unauthorized downloads of the complete track are reduced. For added security, voiceovers or watermarks like “sample” can be incorporated.

10. I’m an audio producer; how can I best use this feature to showcase my work?

Audio Preview is an excellent tool for audio producers to tease their work. By selecting compelling snippets that represent the essence of the full track, you can entice listeners and encourage them to explore or purchase the complete piece.

Updated on November 2, 2023
Was this article helpful?
Still Stuck?
We can help.