Visual waveform
The waveform is drawn on a canvas so you can see exactly where to place the trim handles.
Trim an audio file by dragging the start and end handles on the waveform. Preview the cut, then export as WAV, MP3 or OGG Opus. Everything runs locally using the Web Audio API — no uploads, no sign-up.
Private by design. The file is read from your device and decoded entirely in your browser using the Web Audio API. MP3 and Opus encoding also run locally. Your audio is never uploaded, stored, or logged anywhere.
or click to browse — MP3, WAV, M4A, OGG, Opus and FLAC
Up to about 100 MB. Files are decoded in memory.
WAV is lossless and works everywhere but produces the largest file.
The waveform is drawn on a canvas so you can see exactly where to place the trim handles.
Pull the start and end markers to any position. The trim length updates live.
Play the file with a red playhead showing the current position. The trim region is highlighted on the waveform.
WAV for lossless quality, MP3 for universal support, OGG Opus for the smallest files. All produced by real encoders that run locally.
Everything happens in your browser. The file is never uploaded, stored, or logged anywhere.
Encoders are cached by the browser after the first download, so later exports of MP3 or Opus start instantly.
Input support depends on your browser, but any format listed below generally works in Chrome, Edge, Firefox and Safari.
| Format | Extension | Input | Export |
|---|---|---|---|
| MPEG Audio Layer III | .mp3 | Yes | Yes (real MP3 encoder) |
| Waveform Audio | .wav | Yes | Yes (PCM 16-bit, lossless) |
| MPEG-4 Audio / AAC | .m4a, .aac | Yes | Choose WAV, MP3 or Opus |
| Ogg Vorbis | .ogg | Yes | Choose WAV, MP3 or Opus |
| Opus | .opus, .webm | Yes | Yes (real Opus encoder) |
| FLAC | .flac | Yes (in most modern browsers) | Choose WAV, MP3 or Opus |
Trimming audio is one of those tasks that seems simple until you try to do it well. Cutting a file is easy; cutting it at exactly the right moment, without introducing a click at the boundary, is where the details matter. A browser-based trimmer that shows you a waveform and lets you drag the boundaries is often the fastest way to get a clean cut, especially for quick edits like removing silence at the start of a podcast or extracting a short clip from a longer recording.
Modern browsers expose a complete audio pipeline through the Web Audio API. A file is loaded as an ArrayBuffer, then decoded into an AudioBuffer — an in-memory representation of the audio samples with a defined sample rate and channel count. From there, the samples can be sliced, mixed, filtered, and re-encoded. Playback happens through an AudioContext, which provides sample-accurate scheduling and lets you control volume, position, and playback rate independently of the underlying data.
This tool uses that pipeline end to end. The uploaded file is decoded into an AudioBuffer, the waveform is drawn by sampling the peak amplitude in each pixel column, and the trimmed output is written in the chosen format by reading the samples between the start and end points.
There is no single best format for every use case. Here is a quick guide:
Until recently, encoding MP3 in the browser was impractical because it required either a native plugin or a huge WebAssembly build. The pure-JavaScript lamejs encoder changed that — it is small (about 200 KB), fast enough for typical trims, and works in every browser without any plugin. For OGG Opus, the encoder is likewise small enough to load on demand. Because both libraries only download when the user actually picks that format, the initial page load stays fast for the common case of trimming and exporting to WAV.
This audio trimmer is part of the TempScript free online tools collection. It runs entirely in your browser, requires no account, and never sends your files anywhere. If you work with media regularly, you may also find our image compressor and PDF merger useful.
© 2026 TempScript. All rights reserved.