Android Enthusiasts Stack Exchange is a question and answer site for enthusiasts and power users of the Android operating system. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am about to encode some of my videos so that they can be played on android devices?

what is the most compatible container, codec and dimension for android devices. thanks!

share|improve this question
You can try Handbrake ( for video transcoding. It supports various profiles and you can google for a configuration for a particular device. See this link I've dug up:… I've used Handbrake (I have a Desire too), and the results are quite satisfactory. – Martin Tapankov Jun 12 '11 at 19:57

The Android Developer Guide covers this pretty thoroughly. They have all the supported formats as well as recommendations. I would additionally recommend using the same resolution as your screen if your device can handle it, that will much improve the quality.

share|improve this answer
ok thanks, so i am trying to encode it to h263 using ffmpeg but my phone still says: this video can not be played – clamp Jun 12 '11 at 14:22
@clamp What device do you have? – Matthew Read Jun 12 '11 at 16:43
HTC Desire with android 2.2 – clamp Jun 12 '11 at 17:07

When I encode movies using Handbrake or DVDFab, I choose the "iPad" option, which create an m4v with h.264 and AAC (I think). Yes, this feels like sacrilege, but I just ignore the voices in my head. ;)

On XOOM, this plays fine. To keep the file size down, I take the audio down to stereo @ 44.1khz and 96kbps and the video rate to 1200kbps, while still maintaining 720p. This seems to work out alright and most 2 hour movies are in the 1 to 1.5GB range.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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