When a phone, action camera, drone or camera stops recording unexpectedly - the battery runs out, the card fills, the app crashes, the camera is switched off - the video and sound are usually all there, but the file is never finished. Its index, the part that says where every frame and every slice of sound is (the "moov atom"), is written last, so it is missing, and players say the file is corrupt, show nothing, or play a few seconds. Repair services charge for this and want the file uploaded.
This page rebuilds the index in your browser with untrunc, the open-source repair program people have used for years, compiled to run here. It reads a working video from the same camera to learn how that camera lays out its picture and sound, finds every frame and sound packet in the damaged file, and writes a new index in front of them. Your files are read where they are, so even recordings of many gigabytes work, and nothing is uploaded.
The good video only has to be a few seconds long - 10 seconds or more is safest, as it shows the repair more of how the camera stores its frames; a clip with just one keyframe (a frame that stands alone, which some cameras put only every few seconds) works too - but it must come out of the camera exactly as the broken one would have: same device, same mode, same settings. If you are not sure what the broken clip was recorded with, record a short clip now with the settings you think you used; if the repair finds nothing, change one setting and try again. For an H.264 recording the page also looks at how its frames are coded: a working clip filmed in the simpler Baseline mode (CAVLC, which some cameras and apps use for compatibility or lower quality) cannot stand in for a recording coded in Main or High (CABAC), and when the recording's frames read as CABAC against such a clip, the page warns before the repair that it will probably not work. These are the settings that matter for each kind of device.
As of October 2026, from each product's own pages and documentation. Prices and plans change, so check before you buy. Names belong to their owners.
- My video plays in VLC but not on my iPhone, Mac or in QuickTime. Why?
- Often because it is HEVC (H.265) tagged hev1: both hev1 and hvc1 mean HEVC in an MP4 or MOV, but Apple's players only accept hvc1. FFmpeg, HandBrake and many cameras and screen recorders write hev1, so the video opens everywhere else and stays black or refuses to open on Apple devices. Drop the file here: the page reads its tag, and Make it play on Apple devices saves a copy tagged hvc1 - a few bytes change, nothing is re-encoded and the quality is exactly the same. When the settings Apple needs are only inside the video stream, not in the file's index, retagging is not enough, and Make it play on any phone re-encodes it as H.264 instead.
- My video plays on my computer but not on my phone, or my editing app will not take it. Why?
- Usually the file is not damaged: it is in a format the phone or app does not play. Many dashcams, action cameras and security cameras record HEVC (H.265), Motion JPEG or an AVI, which a lot of Android phones, older ones especially, and phone editing apps refuse. Drop the file here: if the page finds nothing wrong with it, Make it play on any phone converts it to an H.264 MP4, with any sound as AAC: the format every phone, editor and browser takes. It is encoded again, so it takes a few minutes for a long video and the quality drops very slightly.
- Why do I need a second video?
- The damaged file has the picture and sound but not the description of them - which codec, what resolution, how the camera arranges frames and sound. A finished video from the same camera, with the same settings, carries exactly that, and the repair copies it. A clip with a different resolution, frame rate, codec, or HDR or stabilisation setting will not match.
- The repair says no video was found. What now?
- Almost always the pattern clip does not match, and the page says how when it can tell - for example the damaged file is HEVC and the pattern H.264, which on an iPhone is the High Efficiency against Most Compatible setting - or, just as often, a clip picked from Photo Library, which the iPhone can convert to H.264 as it hands it over; save it to Files and pick it from there. Check it was recorded on the same device with the same resolution, frame rate and settings, or record a new few seconds with them. Try the thorough search too, which steps over damaged stretches. If the damaged file is all zeros - which happens when a card or phone never saved the data - the page says so as soon as you choose it: there is nothing left to recover.
- The repaired video is black or silent. What went wrong?
- The page checks every result before offering it: it decodes about 16 frames from all through it (6 when the browser cannot decode the picture itself and FFmpeg does it instead) and a few seconds of the sound. When every frame that decodes is black or one flat colour, the decoder reports errors decoding its keyframes (a working clip that does not fit), or most will not decode, it says No usable picture was recovered instead of Repaired, and lists what to try next; the file can still be saved. (A file repaired from its own settings whose picture is black but whose sound is fine is most likely how it was filmed - a lens cap or a covered lens, a dark scene, or a camera setting - and the page says that instead, both before a re-encode and on the result. If you press Continue anyway past that, the result is still called No usable picture was recovered, never Repaired.) Sound that is silent in every stretch checked is pointed out too. A dark recording is not mistaken for a black one: even a night scene has some light or grain in it, and only a picture that is one flat shade all over counts as black. When a result is black or silent, there are four usual causes. The format, not the repair: phones, drones and action cameras often record HEVC (H.265), which Windows and some browsers cannot show without hardware decoding or Microsoft's HEVC Video Extensions; the picture stays black while the sound plays, or the page says it cannot preview the video. Save it and open it in VLC, which plays HEVC on its own, or in Edge or Chrome on a computer whose graphics can decode HEVC (Edge also needs the HEVC Video Extensions), or press Make it play on any phone (converts to MP4) beside an HEVC result, which makes an H.264 copy that plays everywhere. A working clip that does not match: the frames are read with the working clip's settings, so a clip from another device, or the same one in another mode (4K against 1080p, 60 against 30 frames a second, HDR, stabilisation, HEVC against H.264), gives a picture that will not decode, or one that is mostly grey with fragments of picture: the decoder fills what it cannot read with grey. The check catches that too: it has FFmpeg decode the first few keyframes on their own, which decode without a single error when the clip fits, and with errors - on every one, or with the picture left as grey or empty blocks - when it does not. A picture that is merely dark or grey, such as a night scene or a grey wall, decodes without errors and is not counted against the repair. Record or pick a clip from the same camera in the same mode, and try the thorough search. Repair without one guessed wrong: without a working clip the page works the settings out from the recording, and for an iPhone it assumes the usual 1080p HDR mode; a video filmed another way comes out garbled or black, and a working clip from the same phone in the same mode fixes it. Nothing was there to recover: when under a second of picture matches, the page says no video was found rather than giving you a black file, and offers the sound on its own when that survived; a file that is all zeros never had its data saved.
- Do I always need a second video?
- No. A video whose download or copy stopped part way - or one from a camera that writes its index at the start - usually still has its index, and only the end is missing. The page notices this as soon as you choose the file, and rebuilds the index to stop where the data does, with no second video. Everything up to the cut is kept. And when there is no index and no second video to hand, Repair without one rebuilds the picture from the recording alone, if the camera kept its H.264 or HEVC settings inside the video as most dashcams and security cameras do. An iPhone keeps them only in the index, but uses the same ones for every video filmed in its usual setting (1080p HDR, High Efficiency, 24 or 30 frames a second), so the page knows those and rebuilds such a recording with its frame rate and stereo sound; other iPhone modes still need a working clip. The sound usually comes back too: AAC, what phones, action cameras and most dashcams record, is found by decoding the data between the frames under each usual setting until one fits, then copied as it was; plain PCM, as many dashcams and Sony cameras record, is recognised by its shape. The format is worked out rather than read, so if the sound plays at the wrong speed, a second video gets it exactly. A file whose index is whole needs none either: when it opens normally here, pressing Repair says so straight away, before any working video is looked at.
- Can it fix a video that plays with glitches, or a file that was deleted?
- Glitches, yes. A video that opens but stutters, freezes, shows blocks of grey or green, or crashes an editor has damaged frames in it: press Fix glitches (re-encodes); for a file the page finds complete, the button is Make it play on any phone, which does the same. Every frame is decoded, a damaged one is patched from the frames around it rather than breaking the picture until the next keyframe, and the video is encoded again as H.264 with the sound as AAC, keeping its length and its sound in step. It takes a few minutes for a long video - the page shows the time taken and roughly how long is left as it goes, and for one that could take more than 20 minutes at its size asks first and suggests cutting it into parts in the Video Cutter. For a repaired or damaged video, if every frame checked from all through it is black, or more than half the frames in the first stretch of an H.264 video are too damaged to decode, it stops and says so, with Continue anyway beside it; a complete video is never stopped for being dark or black. The quality drops very slightly, and what was lost stays lost - a patched frame is a best guess - but the result plays smoothly everywhere. The same button appears after any other repair, for a repaired video that still plays badly. Deleted files are another matter: getting them back from a card needs a recovery program such as PhotoRec (free) first, then this page if the recovered video will not play.
- A recovery program got my video back, but it will not play. Can this help?
- Often. Recovery programs sometimes hand back a file whose index is whole but points at the wrong place: every frame sits the same number of bytes before or after where the index says. The page checks frames through the file as soon as you choose it, looks for where they really are, and says so when it finds them; the repair then corrects the index and nothing else, in a moment. If the frames are not anywhere nearby - the program put other data in their place - it says that instead, and running the recovery again, or another program, on the original card is the way to go. A recovered file with no index at all is repaired like a cut-off recording, with a working video from the same camera or Repair without one.
- My video freezes part way through and will not play past that point. Can it be fixed?
- Often, yes, and without a second video. When a file was copied or downloaded with gaps - a transfer that skipped part of it, a torrent that never finished, a bad patch of a memory card - the index is whole but some of the data it points to is zeros or junk, and players stop there. The page checks frames all through the file as soon as you choose it and says if it finds this. The repair copies every whole frame, leaves out the damaged ones and the frames that depended on them, and keeps every frame at its real time: across each hole the picture holds still, then carries on in step. Where the sound was damaged too, ordinary AAC sound (what phones and most cameras record) goes quiet; other sound is kept as it was, so a hole of zeros in uncompressed sound is silent and damaged compressed sound may click or skip. Nothing is re-encoded. What was in the holes is gone, but everything else plays.
- Can it repair FLV, MPG, VOB or WMV files?
- Yes, without a second video. These older formats go wrong in the same few ways: no length, no skipping ahead, a stop at a damaged spot. The page reads the file in a way that steps over damage and copies the video and sound, untouched, into a new file with a fresh index - an MP4 when the video is H.264 or MPEG-4 with AAC or MP3 sound, otherwise an MKV, which VLC, Windows and most players open. To get an MP4 that plays everywhere, including in a browser, use Convert or shrink it on the result, or Still plays badly? to re-encode it as H.264 with damaged frames patched.
- VLC says my AVI's index is broken or missing. Can it be fixed for good?
- Yes, with no second video. An AVI keeps its frames and sound in one long list and the index of where each one is - written last - after it, so a recording that was cut off (a dashcam or CCTV recorder losing power, a full card, a crash) has no index, sizes that were never filled in, and often a half-written last frame. Players then refuse it, show no length or cannot skip, and VLC offers to fix the index only while the file is open. Drop the AVI in and the page says what is wrong with it; Repair finds every frame and slice of sound that is there, across all the parts of a large (OpenDML) AVI over 1 GB and past where a cut-off file's sizes say it ends, steps over damaged stretches, leaves out a frame the file stops part way through, and saves a new AVI with the sizes and frame counts corrected and a new index with the keyframes marked (worked out from the frames themselves for Motion JPEG, Xvid and DivX, H.264 and the other usual codecs). Nothing is re-encoded. Copy into an MP4 then copies the picture, untouched, into an MP4 (or an MKV, for codecs MP4 players do not expect; PCM sound going into an MP4 is made AAC); H.264 video can then be watched right here. What it cannot do is bring back frames that were overwritten, zeroed or never saved: the picture jumps where they were, and since an AVI has no timestamps the sound can drift slightly out of step after a damaged stretch.
- Can it repair an .MTS or .M2TS file from my camcorder?
- Yes, with no second video. AVCHD camcorders (Sony, Panasonic, Canon) and Blu-ray save transport streams, which have no index to lose; what goes wrong is a stretch the card never wrote, packets the camera marked as damaged, or junk in front, and players stutter, freeze or give up there. The page reads the whole stream, says what it found, steps over the damage and copies the good video and sound into an MP4 that plays and seeks everywhere. Nothing is re-encoded, except sound MP4 cannot hold - Blu-ray PCM, DTS, Dolby TrueHD and LATM AAC (from some TV broadcasts) - which is made into AAC.
- After the repair the sound is slightly out of step. Can I fix it?
- Yes. Under the repaired video, move the sound 0.1 seconds earlier or later as many times as you need, watching the preview, then save. Only the index is changed, so it takes a moment even for a huge file, and the picture and sound themselves are untouched. If the sound drifts further out of step as the video goes on, the camera recorded at a varying frame rate: that is fixed automatically when the repair notices it.
- My WebM or OBS recording has no length and will not skip ahead. Can it be fixed?
- Yes, on its own. WebM and MKV files - what browsers, screen recorders and OBS save - write their length and the index players use to jump around when recording stops, so a recording that was not stopped properly plays from the start but shows no length (or the wrong one) and cannot be scrubbed, and one cut off part way may stop early. Drop it in and press Repair: every frame is copied, untouched, into a new file of the same kind with its length and index written, and a file cut off in the middle keeps every whole frame up to the cut. Nothing is re-encoded, so it takes seconds.
- Can it repair a voice memo or another .m4a recording?
- Yes. A voice memo or call recording that was cut off - the phone died, the app crashed - has the same problem as a video: the sound is there but its index is missing. Drop the .m4a in, add a short recording made with the same app and quality setting, and the page rebuilds it and plays it back before you save it. It can then go straight to the Audio Trimmer or to Audio to Text for a transcript. A damaged MP3 is repaired with MP3 Repair.
- Do my videos get uploaded for the repair?
- No. Both files are read by your browser, in place, and the repaired video is built on your computer. Nothing about them is sent anywhere, which also means a 20 GB recording takes no upload time.
- What is untrunc, and where is its source?
- untrunc is free, open-source software (GPL) by Federico Ponchio and contributors. The copy here is FootageRescue's WebAssembly build of it; its full source, the FFmpeg it includes, and the two small changes made here are published at johnmcm.com/source/untrunc. Office documents that will not open are handled by Repair Office File.