OGG files in browser games
OGG is a free, compact audio format that works on Go Bananas even on iPhones, because the site turns every OGG into an MP3 that plays everywhere.
OGG is an open, royalty-free container for compressed audio, most often in the Vorbis format. It sounds about as good as MP3 at the same size or a little better, and many game tools and sound libraries offer it. Its catch has always been browser support: Safari on older iPhones and Macs couldn't play it.
What OGG is good for in games
OGG suits both kinds of game audio:
- Sound effects. Short clips are small and quick to load.
- Music. Long tracks stay compact, which matters with a 5 MB limit per file.
Game engines and free sound sites often provide OGG, so it's a common format to have on hand. If you have both an OGG and a WAV of the same sound, the OGG is the one that fits the size limit more easily for anything longer than a few seconds.
On Go Bananas, every audio upload is turned into an MP3, so your game never plays the OGG itself. That removes the old Safari problem: the MP3 the site makes plays in every browser and on every phone. The format you start from mostly decides how good the audio sounds going in and whether the file fits the 5 MB limit.
Uploading OGG to Go Bananas
You upload audio in the Upload Asset window. Open it from the Assets tab ("Upload Asset") or from the editor ("Upload New", or drag a file onto the editor chat). If you drop an audio file on the create panel, the site opens the same window for you.
You need to be signed in with a verified email. Before the upload, you tick a box confirming you have the right to use the audio: it's your own work, it's licensed to you, or it's in the public domain.
| Limit | Value |
|---|---|
| File size | 5 MB per file |
| Length | 120 seconds |
| All your audio together | 50 MB per account |
| Embedded tags | 256 KB |
The site refuses a file it can't read. Then it prepares the sound for games:
- It sets the loudness to -16 LUFS, so every sound in a game plays at a similar level.
- It trims silence at the start of the file. Silence at the end stays.
- It removes all metadata, such as artist and title tags.
- It saves the result as an MP3 at 44.1 kHz. A clip of 5 seconds or less is treated as a sound effect and saved in mono at 96 kbps. A longer clip is treated as music and saved in stereo at 128 kbps.
The OGG itself isn't kept, only the MP3 made from it. The site warns you if the audio is clipping (distorted) or unusually quiet or loud. You can trim it to the part you want, and games then play only that part. The file isn't cut, so you can change the trim later.
Using OGG in your game
The easy way: ask the AI. In the create or edit box, type @ and pick your sound. Its name is inserted in quotes, for example "forest-theme", and the AI knows which file you mean. In the editor's Assets tab, attach the sound to your game to set its volume with a slider from 0 to 100.
In code. Every game has a sound helper, window.__audio. Your sound's address is in window.GAME_ASSETS.audio, under the file's name without its extension. The address points to the MP3 the site made:
const themeUrl = window.GAME_ASSETS.audio['forest-theme'].url;
const stepUrl = window.GAME_ASSETS.audio['step'].url;
// Browsers, and iPhones especially, only allow sound after a tap or click
document.addEventListener('pointerdown', () => {
__audio.init();
__audio.playMusic(themeUrl, { loop: true, volume: 0.4, fadeInMs: 1000 });
}, { once: true });
__audio.load(stepUrl);
function onStep() {
__audio.play(stepUrl, { volume: 0.5 });
}
playMusic fades the track in and loops it by default. For 3D games, __audio.play3D(url, x, y, z, camera) makes a sound come from a point in space, quieter the farther away it is.
Pass the full address: a bare name or an asset ID won't play. Use the helper rather than new Audio() or your own AudioContext. It unlocks sound on iPhones, follows the site's mute button, and applies the volume you set in the editor.
Built-in sounds
Every game can also use a free sound pack, released as CC0 (no permission or credit needed). Each sound lives at https://gobananas.co/sfx/<name>.mp3:
gunshot,reload,hit,footstep,pickup,menu_clickzombie_moan,zombie_attack,zombie_deathambient_tension, a music loop of about 10 seconds
Use the full https address in game code. The editor's volume slider doesn't apply to these sounds, so set their volume in the play call.
Tips and common problems
- Keep the original. The site keeps only the MP3 it makes. Every lossy conversion loses a little, so upload from the best version you have rather than an OGG that was itself converted from an MP3.
- The file is over 5 MB. Export it at a lower quality setting or shorten it. The 120-second limit applies whatever the size.
- Silence at the end. Only the start is trimmed. Trim the end in the editor, or cut it in your audio editor.
- A clipping warning means the recording is distorted at its loudest moments. Lowering the volume later won't fix it; re-export from the original at a lower level.
- The game can't find the sound. Its name in
GAME_ASSETS.audiois the file name without.ogg. If you rename the asset, game code that uses the old name stops finding it. If two files have the same name, the newest one wins.
From ChatGPT or Claude
Audio can't be sent through the Go Bananas app in ChatGPT or Claude. Ask for an upload link: it takes you to your game's page, where you upload the file from the editor.