Stretching can be a good idea. Muscles at full length are essential to optimal metabolism, circulation and joint space. but what's more important is to ask yourself this: why does this area of my body need stretching all the time?
Let's keep hamstrings as our example.
The "underused muscle" scenario
Your hamstrings may need stretching because of being kept inactive and in a shortened position for a large part of the day, due to many hours spent sitting, or bending at the knee when standing. Keeping your hamstrings lengthened (think "straight legs") will help a lot BUT they may also need strengthening, ie contracting/moving. Not to mention that your bones will need to be aligned, to make sure you don't stretch your ligaments instead of your muscles, particularly if you suffer from joint hyperlaxity. You also want to make sure that you don't stretch another muscle without realising it. Don't think that because you can touch your toes, your hamstrings are at the right length. As soon as you feel your lower back round, you are NOT stretching your hamstrings.
The "overused muscle" scenario
What if you're very active? Your hamstrings may be tight because of being overused. They may have to work harder to compensate for your gluteus maximus being too weak and not doing its job, which is very common.
How about knots?
Your muscles may be shortened due to knots, so-called trigger points that need to be deactivated. Stretching will only help after the knots have been released. You can do it yourself with a tennis ball, a good stretch and the application of heat afterwards. For more reluctant knots, it is worth making an appointment.
The long-term solution for permanently short hamstrings? sit for shorter periods, sit/stand, walk more, step on fallen logs in the woods, climb, take the stairs rather than the lift, sleep with your legs stretched out, learn to engage your hip muscles when you move, learn to correct your alignment using objective bony markers and learn to stretch effectively.
A lot of serious problems start with tight muscles. This is why it is important to not ignore muscle tightness and to consult a qualified therapist, who, through observation, palpation and muscle testing, can detect problems and prevent a host of very unpleasant complications.
Stretching on its own won't do much to produce a change. You really need to look at the whole picture, i.e. how you use your body throughout the day, every day. There are many factors to take into account, and every body is different!