I thought that when you add a MP3 sound to your game, the new Unity setting called 'Gapless looping' would solve that for you automatically.
The problem in my case was that the property was disabled.
After searching for answers on Unity questions and answers, Google etc I have found the solution myself!
The trick is to export your music as WAV. Meaning that it will be added to Unity as an uncompressed audio file. Next, select the audio file and watch the properties in the inspector. As you can see the drop down shows WAV and most of the other options are grayed out. Now, select MPEG from the drop down. By doing that we are telling Unity to compress the WAV file.Watch what happens with the other properties: they become enabled!
Next, select Gapless looping and the other settings. If you are using the file as background music you might want to set priority to 0 for instance to prevent the sound from being swapped out. Also it probably doesn't make sense to have 3D background music as the volume and panning does not apply to the position of your listener.
Finally click Apply and Unity will start creating the MP3 file for you. Add an empty game object to your game, add an Audio Source component to it and select the Audio clip. Make sure looping is enabled and start your game!
The music should loop perfectly. So to summarize: don't import MP3 files into Unity but instead import WAV and let Unity create the MP3 for you. That way you can create nice looping background music.
Enjoy!



