[Android Software/Hacking General [Developers Only]] loveubuntu:
You can skip the story and go to the solution at the bottom if you don't care about the origin of the problem. This may help some ROM designers.

It appears that Yahoo may not want us to know this fix and is pushing us to use their Yahoo Mail app in the market. It is a pretty good app and is a nice alternative to this. But the stock email is quite fast in skimming /deleting emails from multiple accounts.

Story: When the original Droid came out, one of the first issues was that people with Yahoo Mail! (free accounts) could not use the stock MAIL application to set-up their account. We had to go to the website through the web browser to check email.

Then people all over these forums and other Droid forums came out with the "IMAP" work around. And it did work. The problem was that if you had your account setup to leave a copy of any email you send in your SENT folder, you'd get 700-1000 of the same copy in that folder. Mine was around 27000 emails in one folder in a few days. Annoying but as soon as I turned that "keep a copy" feature off, I was OK. But I still wanted a copy of my sent emails.

Motorola, Google, Verizon, or Yahoo came up with a fix and we all got it with the first OTA (over the air) update. Everything was great. But then I rooted my phone and tried all kinds of custom ROMS. In the mean time Yahoo came up with their own Yahoo Mail app (currently pretty good app, if you'd ask me).

Problem: Some of the ROMS appeared to be like the original Droid and not let Yahoo mail set up but some where fine with it. Unfortunately, my favorite ROM, MIUI, was of the ones that had problems setting this up. After talking with Jamezelle and him pushing me to find out what the fix was, I flashed my original ROM (right before I rooted) to see what was different in the settings. It seems like the IMAP solution is still in place but with slight modification to avoid multiple sent items being stored. The IMAP solution I have seen in all Internet forums do not mention this slight fix, hence, not a complete fix.

Solution:

The real FIX: I did not come up with this fix, I only poked around the phone to see what was different from what Verizon had pushed OTA in early 2010 that was not in many of the custom ROMs.

Please double check spelling as you enter into fields

1- Go to your mail app, press menu, add account. make sure you have erased any account you may have setup for this yahoo account. Long press and remove

2- enter email address, make sure it's your complete email address, and then enter your password

3-- press manual setup (lower left)

4-enter your username, this is your whole email address, fill out what you are missing (the @ sign and domain), your password is there

5- Here is the modification, the imap server is:

android.imap.mail.yahoo.com

the android part is new

6- Port: change port to 993

7- security type : choose SSL, imap path prefix stays empty, click next

if you have entered anything wrong you will get an error, check everything again. If OK, you go to the SMTP settings:

8- SMTP server:

android.smtp.mail.yahoo.com

note the difference from above and the android word is also new.

9- Port change to 465,

10- Security type: SSL, and check the box for require sign in (important)

11- again make sure your whole email address is in the username field, your password is already entered.

If you keep getting an error after the SMPT setting, try connecting through WiFi and then repeat the steps. You may have to choose no encryption and then later change it to SSL I had a hard time setting up one of my droids but it did finally take it. Keep at it and it will work.

click next, if you get any error, you did something wrong. If everythig is OK, it will take you to the page to name the account and how frequent you want to check for emails. Finish it up and you are done.