While the iPhone Mail App in iOS 4 has some really nice improvements there has definitely been a regression in stability. Recently I had an issue on my 3GS where the Mail App would constantly crash a couple seconds after starting. Here is how I fixed it without resetting the firmware.

Note that my phone is running firmware version 4.0.1 and is Jailbroken. I could not fix the Mail App problem on its own and ultimately used the iFile App to fix the issue. If you're running 4.0.1 and haven't Jailbroken your phone yet then what are you waiting for? It couldn't be any easier. If you're running 4.0.2 then sorry, you're out of luck.

After a ton of searching on the Internet I found that a lot of people are experiencing immediate Mail App crashes on iOS 4. The general consensus is it has to do with either a) problems with pending mail in the outbox or b) with bounced undeliverable messages. For me I think it started with a bounced message but am not totally sure. Ultimately, even after I deleted all mail accounts the Mail App would still crash. So stupid and incompetent by Apple.

Here is how I fixed the problem:

  1. Go under settings and delete ALL your mail accounts.
  2. Start iFile or login to your phone via ssh.
  3. Go to /var/mobile/Library
  4. DELETE the Mail directory. That's right... DELETE it entirely. It will get automatically created later.
  5. Reboot your phone.
  6. Go under settings and add your mail accounts.
  7. The Mail App should no longer crash and work properly.

Screw you Apple... :-(