Do a web search on "exercise and depression" and you'll find numerous articles and studies citing how exercise can help people combat depression. According to the UK Mental Health Foundation, there's a range of reasons why exercise can help with depression:
Exercise is believed to increase the release of the brain chemicals that affect our mood and make us feel happier.
Exercise helps us to get active and meet new people. This stops us from feeling isolated and unsupported.
Exercise can give us new goals and a sense of purpose. We have something positive to focus on and aim for.
Exercise can boost our self-esteem - it can improve the way we look and how we feel about ourselves.
Of course, depressed people often feel devoid of energy, and exercise is the last thing they feel like doing. Which is why it is important to find something fun, and to start gently. Exercise doesn't just have to be the gym - it can be dancing, walking, swimming, yoga or a sport. One of Tony Robbins' favourite lines is "motion creates emotion", the message being, the less in motion a person is, the worse they are likely to feel.
So even for someone who feels they cannot get out of bed, going for a regular walk, whether they feel like it or not, can make a huge difference.
In the UK, many GPs can "prescribe" exercise for patients, referring them to schemes where they will be helped to develop their own personal exercise programme, under the supervision of a qualified trainer. The exercise sessions are often provided free, or at a significantly discounted price. There are around 1,300 schemes like this operating in the UK. Your GP will be able to tell you if there is a scheme in your area. More information on the scheme from the Mental Health Foundation Up and running! factsheet.
For people in other countries (and those in the UK!), there is also a book about exercise and depression called Exercise beats depression, by Jim Johnson. Available from online booksellers.
Irrespective of whether you are exercising, try to continue with any hobbies or interests you have. Even if you have no motivation to do them when you are depressed, try and do them anyway, especially if they will put you in the company of other people. You are much more likely to feel better out the house doing things, than staying in with only your own thoughts for company.