Convert M4B to J2B — Free Online Tool
Convert M4B audiobook files to J2B format using the LAME MP3 encoder directly in your browser. This tool decodes AAC audio from the MPEG-4 container and re-encodes it to the ASYLUM Music Format-based J2B container used by Jazz Jackrabbit 2, with no server upload required.
to
FFmpeg Command
Copy this command to run the same conversion locally with FFmpeg on your desktop. Download FFmpeg
Drop your M4B file here
or click to browse
Free — no uploads, no signups. Your files never leave your browser.
Settings
Note: Browser-based encoding uses approximate quality targets. For precise CRF compression, copy the FFmpeg command above and run it on your desktop.
Estimated output:
Conversion Complete!
DownloadHow It Works
M4B files store AAC-encoded audio inside an MPEG-4 container, typically with chapter markers, bookmarks, and ID3-style metadata designed for audiobook playback. J2B is a game-specific audio format used by Jazz Jackrabbit 2, built on the ASYLUM Music Format wrapped in a proprietary header. Because these two formats share no codec or container compatibility, a full transcode is required: FFmpeg decodes the AAC audio stream from the M4B, then re-encodes it using the libmp3lame encoder to produce MP3 audio, which is then written into the J2B container. Chapter markers, bookmarking data, and podcast metadata present in the M4B will not carry over, as J2B has no mechanism to store such information. This is a lossy-to-lossy conversion, meaning the audio undergoes a second generation of lossy compression, which will result in some additional quality degradation compared to the original source.
What Each Flag Does
| Flag | What it does |
|---|---|
ffmpeg
|
Invokes the FFmpeg multimedia processing tool, which handles the full decode, transcode, and remux pipeline needed to move audio from an M4B audiobook container into a J2B game audio file. |
-i input.m4b
|
Specifies the input M4B audiobook file. FFmpeg reads the MPEG-4 container, identifies the AAC audio stream, and prepares it for decoding ahead of the libmp3lame re-encoding step. |
-c:a libmp3lame
|
Selects the LAME MP3 encoder for the audio stream. Since J2B requires MP3-encoded audio and M4B carries AAC, a full transcode through libmp3lame is mandatory — there is no stream copy option available for this format pair. |
-b:a 128k
|
Sets the MP3 audio bitrate to 128 kilobits per second for the J2B output. This is a common balance point between file size and audio fidelity for speech and mixed-content audiobooks, though the effective quality ceiling is limited by the original AAC encoding in the M4B source. |
output.j2b
|
Defines the output filename and instructs FFmpeg to write the libmp3lame-encoded audio into a J2B container. FFmpeg infers the J2B format from the file extension and applies the appropriate container wrapper around the MP3 stream. |
Common Use Cases
- Repurposing M4B audiobook narration audio as custom background music or voice clips for Jazz Jackrabbit 2 level mods
- Converting M4B-format spoken-word content into a J2B file for experimental game audio hacking or retro game modding projects
- Extracting and repackaging AAC audiobook audio into MP3-based J2B for archival testing of the ASYLUM Music Format wrapper
- Creating custom J2B audio assets from M4B podcast recordings for use in JJ2 community-created levels or fan projects
- Testing J2B container compatibility and LAME encoder output by feeding known-good M4B audiobook files through the conversion pipeline
Frequently Asked Questions
No. J2B is a minimal game audio format based on the ASYLUM Music Format and has no support for chapters, bookmarks, or any audiobook-style metadata. All chapter structure, playback position data, and ID3 tags present in the M4B will be discarded during conversion. If preserving chapter information matters, you should export the M4B to a format like MP3 with embedded chapter cues or retain the original M4B alongside the J2B output.
M4B files use AAC encoding, which is a lossy format. When FFmpeg decodes the AAC stream and re-encodes it with libmp3lame for the J2B output, the audio undergoes a second round of lossy compression. Each generation of lossy encoding introduces additional artifacts, so the J2B output will sound slightly worse than the original M4B, even at the same bitrate. This is an unavoidable consequence of the codec mismatch between the two formats — there is no lossless pathway from M4B to J2B.
The default 128k bitrate is a reasonable starting point for most content, but since this is a lossy-to-lossy transcode from AAC, encoding at a higher bitrate than the original M4B source offers diminishing returns and will not recover quality lost in the first encoding pass. For speech-heavy audiobook content, 64k or 96k is often sufficient for intelligible playback. For music or high-fidelity podcast audio, 192k or higher will better preserve the decoded audio before it is re-compressed by libmp3lame.
J2B files are natively associated with Jazz Jackrabbit 2's game engine, but the game typically plays back tracker-style module music rather than MP3-encoded audio wrapped in a J2B header. FFmpeg's J2B output is technically valid container-wise, but compatibility with the JJ2 game engine's audio playback system is not guaranteed and depends on how the game reads and interprets the J2B header. This tool is most useful for format research, modding experiments, or toolchain testing rather than producing drop-in game-ready assets.
Replace the value after the -b:a flag in the command. For example, to encode at 192k instead of the default 128k, change the command to: ffmpeg -i input.m4b -c:a libmp3lame -b:a 192k output.j2b. Supported bitrates for the libmp3lame encoder include 64k, 128k, 192k, 256k, and 320k. Keep in mind that because the source M4B audio is already AAC-compressed, increasing the output bitrate beyond the original source bitrate will not restore lost quality.
The displayed command processes a single file at a time, but you can adapt it for batch processing in a shell script. On Linux or macOS, use: for f in *.m4b; do ffmpeg -i "$f" -c:a libmp3lame -b:a 128k "${f%.m4b}.j2b"; done. On Windows Command Prompt, use: for %f in (*.m4b) do ffmpeg -i "%f" -c:a libmp3lame -b:a 128k "%~nf.j2b". The browser-based tool on this page processes one file at a time, so the FFmpeg command is the practical option for bulk conversions or files over 1GB.
Technical Notes
The M4B-to-J2B conversion involves two fundamentally different format philosophies. M4B is a feature-rich MPEG-4 audiobook container with AAC audio, chapter atom support via the iTunes chapter format, and the -movflags +faststart optimization for streaming. J2B, by contrast, is a compact game audio wrapper from the late 1990s, designed to carry ASYLUM Music Format tracker data for Jazz Jackrabbit 2, not general-purpose audio streams. FFmpeg supports J2B output by wrapping libmp3lame-encoded MP3 audio in the J2B header structure, but none of M4B's rich metadata ecosystem — chapters, artwork, author tags, podcast feed data — has any equivalent field in J2B and will be silently dropped. The libmp3lame encoder used here is the standard open-source LAME implementation, which produces compliant MP3 audio at the specified CBR bitrate. Because the input AAC audio must be fully decoded before re-encoding as MP3, processing time scales with the duration of the audiobook rather than just the file size. Long M4B audiobooks with multiple hours of content may take several minutes to convert even in a modern browser using FFmpeg.wasm.