In an attempt to get a good reference and a recommendation from the employer, this resignation letter is polite, grateful, and regretful.
April 15, 2012
Dear Mr./Ms. Bossname,
It is with great regret that I notify you of my resignation as (position) at (company,) effective (date.) I wanted to express my most heartfelt thanks for the wonderful opportunities, positive environment and great leadership that you have provided for me during my time here. I have learned a lot about (subject) over the last (amount of time) and made a lot of friends.
While I have greatly enjoyed the work I have done for this company, it has become necessary for me to leave due to (personal reason, death in the family, relocation, etc.) I will complete all unfinished projects before my departure, and help in any way I can to make sure that my replacement has a smooth transition.
I feel that I have done some of my best work for this company, and I respect your vision and direction when it comes to management. Therefore, I would like to request a general letter of recommendation if it is convenient to you. I will be applying for jobs in (field) and would appreciate your reference.
Thank you once again for your help and understanding.