The iPhone (3GS, 4, 4S, etc) often records video upside-down but then includes metadata about the rotation inside the MOV container.

However, many applications (XBMC, VLC, Windows Media Player) do not understand this rotation metadata and so the videos play upside-down.

Is it possible to permanently rotate these videos and remove/ignore the rotation flag?

  • If your concern is to have it done without re-encoding, it's not really possible. If the video was MJPEG, it would, but the way more sophisticated video codecs like h.264 work is quite different. They really depend on the left-to-right and top-to-bottom order of a picture. You might just want to look for a way to display them rotated or re-encode them with a very high quality.
    – slhck
    Dec 27, 2011 at 18:54
  • VLC allows me to rotate them (during playback), but XBMC does not. How can I re-encode them but keep almost all of the original quality?
    – SofaKng
    Dec 27, 2011 at 18:58
  • Well, I assume you're on Windows. Here's a related question: How do I rotate video (MOV) file on Windows? — the trick is to just set the highest possible quality settings when exporting, which might result in a bigger file than the original. I'm not 100% sure, but it seems you're in a rather bad situation. FFmpeg also has the -vf rotate=1 option to achieve the same. The output options will need tweaking though, to get decent quality.
    – slhck
    Dec 27, 2011 at 19:04
  • Could you maybe provide a short sample clip of such a video? Trying to experiment a bit.
    – slhck
    Dec 27, 2011 at 20:17

1 Answer 1


I had the same problem.

You will need to use Apples iMovie Editor or Quicktime. on an Apple Quicktimepro is included free.

You can purchase Quicktime Pro for windows - You will get the same lossless experiences for rotating, cutting and re saving to a new lossless HD file.

Using iMovies - It will automatically republish your video in a lossless format, with transitions,cuts,pastes,audio,etc. In the correct orientation without manual rotation.

For Windows or other OS's there is no FREE method to do it and its best to use the Quicktime library at all time.

Using windows.. you will have to re encode it --- I searched and searched. only Quicktime will play it in the correct orientation.. but you cannot tell it to fix the original file. Seems a bit odd.. but that was Steve Jobs philosofy.. It always works like you want on a MAC ;)

  • 1
    I don't think you understood the issue. If you're on a Mac, opening such a movie file, the rotation flag will automatically be read. Also in iMovie. There's no need to rotate the file itself, because QuickTime (for example), will correctly interpret it. The reason it doesn't work on Windows is that you have to re-encode, because no player respects the flag.
    – slhck
    Dec 27, 2011 at 20:12
  • 1
    HI - using iMovie export.. will export it rotated.. on windows.. it does not re flag it.. So 1- Import into iMovie(on a mac) 2-Export to HD-HQ 3-Play on windows(will be rotated to proper aspect) Quicktime on Mac supports proper on the fly transcoding with minimum quality loss) Thats what i meant.
    – Piotr Kula
    Dec 28, 2011 at 20:21
  • 2
    Ah.. so there's a need to re-encode, right? iMovie will automatically rotate but you have to re-encode?
    – slhck
    Dec 28, 2011 at 20:42
  • 1
    Yea something like that- you have to save(export) it but the Mac version of iLife uses the full capabilities of quicktime to quickly "re-encode" it.. Quicktime on Windows is limited. I borrowed a buddues mac to do it, resonably quick. But i realised i made a mistake, and re-encoded a 1 and half hour movie on windows..... 2 days...
    – Piotr Kula
    Dec 28, 2011 at 22:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.