Good bye letters are important in the sense that they can help you sum up your feelings while leaving a work place or a neighbourhood. It is a good way of keeping the people you have interacted with, informed about your departure.
There is no need to go into rambling details about the reasons for your departure. You can just briefly go over the reasons.
It is best to keep the tone of the good bye letters friendly and positive.
If you wish to, you can recount a couple of incidents and the good time you had with your colleagues or your friends. It is courteous to thank the people you were with for all the help and support they offered you, during your stay.
If you are writing to co-workers, you can thank them for all that you have learnt while working with them.
Even if you are leaving for not-so-pleasant reasons, try and keep the tone neutral.
You can leave your latest contact information so that the reader can keep in touch with you.
It would be a nice gesture to offer help of any sort from the new place, once you have settled in. If you are writing to a good friend you can also offer to host him/her once you are settled in your new place.
It is good to end the letter on a positive note, and don’t forget to give your best wishes for the reader’s future.