How can we help?
< All Topics

Add audio/music/sound

Have you ever wanted to add music or other audio/sound to your Power BI Report?

The HTML VizCreator Flex custom visual for Power BI allows you to embed HTML content, including audio and music, directly within your reports. Embedding audio or music can be a useful way to enhance the multimedia experience of your report viewers. Here's what the code looks like to embed audio or music in a Power BI report using the HTML VizCreator Flex custom visual:

HTML = "<audio controls><source src='audiofile.mp3' type='audio/mp3'></audio>"

Replace "audiofile.mp3" with the file name of your audio file, and adjust the type attribute as needed if your audio file is in a different format.

There are different control attributes that can be used. They are also explained in the video below

  • controls: This attribute is used to display standard audio controls, such as play, pause, and volume. This is usually included to provide the user with the ability to control the audio playback.
  • autoplay: This attribute is used to automatically start playing the audio file as soon as the page loads.
  • loop: This attribute is used to continuously loop the audio playback once it reaches the end of the file.
  • muted: This attribute is used to mute the audio playback by default.

Below you can find a report which contains an embedded MP3 song. Simply click play to hear the song.

How to create the measure


Please go ahead and download the sample report to see the measure we used to add the song. You can then replace the URL with the URL of the audio file you want to play.

Please note that we can also host your audio files in our Azure account. Just reach out to us to discuss this option.

Did you know that you can also add videos to your reports?