How to fix a broken MP4/MOV video (ffmpeg reports "moov atom not found")

Let's assume your video recorder (phone, camera, etc.) died while recording an MP4 (or MOV or 3GP ... they are mostly the same container format). If you try to read/analyze it with ffmpeg, it'll tell you that "moov atom not found". The problem is that recorders put the most important part of the video (this so called moov atom) at the end of the video file. It contains the index of the video and the metadata (like codec, etc.). So everything that a video player needs to know to be able to play it back. The reason for this is simple: while you're recording the video, you don't have the full index yet. You only have it, when the recording is finished. And you don't know in advance how long the video is going to be so you cannot simply reserve some space for the index at the start of the recording.

There're tools that let you move the moov atom from the end of the file to the start so internet connected players can start playback instantly when they start downloading the file (instead of having to wait til the entire file is downloaded). However this won't help you if your moov is missing altogether.

It'd seem that this problem is more widespread and there're lots of apps that can help you fix such broken files. Unfortunately that's not the case. Actually I've found only a single app called Grau's Video Repair Tool. It's a bit costly for the average user, but you can buy the license for the repair of a limited number of videos significantly cheaper. However the tool's earlier versions were freeware and if you happen to find a copy online (direct link), you can still use it. Smile Obviously the tool has seen quite a few versions since then, so if the free version does not work, you can still try the current demo version and if it works, you can buy a license for recovery of 5 video files. (P.S.: the free version pretty much works for me ... at least with the broken videos created by my phone's camera app in case it crashes for some reason before the recording is finished)

P.S.: obviously the free version of Grau's Video Repair Tool is hard to come by these days. The official site has removed it long ago and various links to copies become invalid after some time. You should search for the filename that was originally used to publish it: "" This dropbox URL (Google just gave me while searching for alternative locations of the utility) might survive for a longer time.


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

fix mov file

Hi, Smile

Software mentioned in the above blog is quite promising, but i know one more software which i used, when i faced this problem. Few days before I was watching my favorite movie on my laptop but it stops in between while playing and starts giving error message. Later on when I met with my uncle I told this problem to him, he suggested me to use mov repair tool to fix mov movie file. I used this tool and got my movie file back. To know how click on the page links:

Re: fix mov file

Thanks, I'll check it out. It's pretty easy to reproduce my problem, I can create a broken MP4 (one without a MOOV atom) anytime. Smile

Re: fix mov file

Well ... I did give it a go. But when it's first thing upon startup was to ask for my password to "make changes", I quit the app. There was no additional documentation in the downloaded DMG, so I couldn't check what exactly intended the app to do. I don't really think that to use the app I should give it administrative privileges on my Mac. Sorry, this one was a no go for me.

repair MOV file

This is very useful statement.but I found one tool “Remo repair Mov” on internet and it is quite good in repairing MOV file.

Re: repair MOV file

It's the same tool as suggested by aurthur.

It worked!

Grau's HD Video Repair Utility worked, and saved a corrupted video (.3gp from my Droid X) of my daughter getting on the school bus for the first time! Thank you so much!

Avoid the issue during recording.


I had the same issue and found the best way is to have avconv/ffmpeg write the necessary header information right away during recording thus avoiding currupt files. This is done by the "-f ismv" flag, also consider adding "-movflags frag_keyframe". This way, if the recording is interrupted, the file will not be corrupt. Also if you need to stop the recording, send a SIGINT instead of SIGTERM (default signal). This is done by '-2' in the kill command, e.g. 'kill -2 <ffmpeg-pid>'.

Hope this helps!

Re: Avoid the issue during recording

Thanks for the tip. Although I started my post with "let's assume your video recorder (phone, camera, etc.) died while recording an MP4 ...", thus the file to be repaired was not recorded by ffmpeg and the issue cannot be always avoided (eg. battery gets drained, storage gets full, etc.).

Yes, obviously those flags

Yes, obviously those flags won't prevent your recorder vom dying. But it prevents that the partially recorded MP4s are corrupt, because the index/codec information is written for each fragment, thus avoiding the issue of broken MP4/MOV videos when the recorder dies Wink

Re: Yes, obviously those flags

I think we're still talking about two very different things. Your tip works if one uses avconv/ffmpeg to record a video. My problem came from using a phone's camera or a camcorder. How do you "put" ffmpeg into these? Shock Most probably you don't. If you got a hardware (with a firmware) that produces faulty MP4 files under certain circumstances, then you need a way to fix these files. And this is what my original post was about.


I guess if somebody has the right motivation (eg. the recording of his nuptial ceremony gets corrupted due to dead battery and missing moov atom), he finds a way. Wink This is what happened to Federico who eventually came up with an open source (free) solution to his problem. He published his code on his blog (and via github). It's something of a hack and his only goal was to fix the one video he needed to recover. But the basics are there. If somebody would pick up the work Federico started, an open source MP4/MOV fixer (a viable alternative to Grau's Video Repair Tool) could be born.

MP4 Video Repair (for Android) by Iwo Banas

There's a solution for Android devices:
Based on it's description, it seems this one works on the same principle as Grau's Video Repair Tool. The app has in-app purchases so it might ask you to buy some licenses for full video repair, I haven't tested it.

Dropbox url is dead. I have

Dropbox url is dead. I have found another url:

This worked

I had a bad file that I desperately wanted to recover. audio m4a with no atom moov at the end.

Although the frequency is off, I was able to recover the audio otherwise using the steps here:

Good luck to you.

Syndicate content