If you are a musician or music reviewer, or like to produce podcasts for your subscribers, having audio on your WordPress is going to be essential. WordPress makes it simple to upload audio via the Media Library uploader; however, it does not have a built in media player by which to play files. Fortunately, there are others ways around the problem, which we are about to show you in this guide.
HTML5 Audio Player
Using an HTML5 player is the easiest way of playing audio without the use of a plugin, but it is far from the most reliable option and may not work on some themes and conflict with certain plugins. Despite the uncertainty, it is worth giving it a go to see if it works for you.
Using the WordPress Media Library to upload your files, use the following HTML5 tag in your HTML Editor:
<source src="song.ogg" type="audio/ogg" />
<source src="song.mp3" type="audio/mp3" />
Your browser does not support the audio tag.
This will allow you to use multiple sources and point them to various audio formats so that your files will play on different browsers. The downside to this option (apart from the fact that it is not guaranteed to work) is bandwidth. Popular files will consume a significant amount of bandwidth – something that you could definitely do without.
Using a plugin
A more complete way of playing audio on your website is to use a plugin. There are various plugins out there that will help you do this including oEmbed HTML5 Audio, Audio Tube, and Haiku Minimalist Audio Player. To download any of these, simply go to Plugins > Add New in your WordPress dashboard and enter the name of the plugin in the search box.
All of these plugins provide a shortcode so that files can be played without have to deal with HTML. Once again, though, you will have to bear in mind the hosting issues. If you publish a lot of audio, it is well worth considering cloud-based hosting.
Using third party content
Arguably, the best way to add audio to your WordPress site is to use a third-party platform to embed the content. Working much in the same way as YouTube and other video sharing services, websites such as SoundCloud and Bandcamp provide you with audio players that can be added to your website by adding a WordPress shortcode to a text box or directly into a post.
If it is your own audio that you wish to add to your site, you will first need to sign up with SoundCloud or Bandcamp; however, doing so will allow you to stream, tracks, podcasts, and full albums with ease and without the worry of losing bandwidth.