Remove the blank space at the beginning of the MP3 file

Remove the blank space at the beginning of the MP3 file


Sometimes, for example when you’re trying to loop a background song for a main menu, you may encounter an issue where each time the song repeats, there’s up to a full second of silence (or even more). This happens due to how the .MP3 format handles encoding and playback.

You can get rid of this silence in a few different ways:

  1. If you’re downloading the audio from the internet, check if the same track is available in .OGG or .WAV format instead (because most of the time there will the same file in different format).

Available formats

You can also use free tools such as https://www.audacityteam.org/ to cut off and/or convert file.

  1. To cut it off manually, first of all, just drag and drop your file into Audacity (or click File → Open… to manually select it)

Then click on Selection Tool and select small flat part in the beginning

Select the empty audio region

Click on delete key on your keyboard

Silent part will be cut off from your audio clip

After trimming silence

Then you can directly export this audio clip in a different format in the same folder where original file is located

Select File → Export Audio…

Select different format (.ogg or .wav) and choose location where to save new file

Export options

Note: General advice for Unity:

Feature/FormatOGG (.ogg)WAV (.wav)
CompressionLossy (compressed)Uncompressed
File SizeSmallLarge
Audio QualitySlightly reduced (usually negligible)Very high (no loss)
Load TimeSlower (streamed or compressed)Fast (fully decompressed)
Memory UsageLowerHigher
Best Use CaseMusic, voice lines, ambient soundsShort sound effects, UI clicks, SFX
CPU Impact (Runtime)Slightly higher (due to decompression)Minimal

Use .OGG for size-heavy audio (music/voices)

Use .WAV for fast-access SFX that need low latency

  1. Nowadays, there is also an option to auto Trim blank space before first clip in Audacity, so you can just import it, open Export Audio window and check the checkbox without cutting it off manually

Auto trim option

Warning: Sometimes, this might produce worse results than doing it manually!