If you tend toward a posterior tilt, you must move slowly and consciously to avoid reinforcing this bad habit and creating further problems when you practice poses that stretch the hamstrings deeply or require a lot of hamstring flexibility. In seated forward bends, for example, tight hamstrings will pull the sitting bones toward the knees, placing the pelvis in a posterior tilt. If you then reach forward to grab your toes, the movement will come from the lumbar spine, which shifts into a reverse of its normal curve. If you come into this position forcefully or repetitively or hold it for prolonged periods, you can strain or damage the muscles, ligaments, and disks in your lower back.
To avoid injury in these poses, I recommend that most of your hamstring stretching be in poses that make it easier to maintain a normal lumbar curve. These include Supta Padangusthasana (Reclining Hand-to-Big-Toe Pose) and a variation of Utthita Hasta Padangusthasana (Extended Hand-to-Big-Toe Pose) in which you place your foot on a chair, a ledge, or some other support. In both poses, position your stretching leg so you can keep a mild anterior pelvic tilt and a normal lumbar curve. That means not putting your foot up so high in the standing version that the pelvis moves into posterior rotation. Most students with tight hamstrings should start with their foot no higher than the seat of a chair. In the reclining version, keep your buttocks on the floor and use a small rolled towel under the back of your waist to support the normal curve of your lower back. Whether you are lying down or standing, rotate the tailbone and sitting bones toward the back of your body while keeping the knees straight.
With daily work in these poses, your hamstrings will gradually become more flexible, and you'll be able to work on seated forward bends without risking injury to your lower back.
If you have the opposite imbalance—flexible hamstrings and tight hip flexors—make sure you regularly integrate hip flexor stretches into your practice. Such poses include lunges, Virabhadrasana I (Warrior Pose I), and quadriceps stretches. Make sure that you emphasize a posterior tilt, lifting up your ASISs and lengthening the lumbar spine to decompress the vertebrae. Take this same posterior tilt awareness into Tadasana: Lift the ASISs and feel the hamstrings pull down on the ischial tuberosities, but don't grip the buttocks or push the pelvis in front of the line between your shoulder and ankles. Then lift your rib cage away from your waist (especially the back of your waist) and, without gripping your abdominals or restricting your breathing, move your navel toward your spine.
If your hamstrings are really flexible, they may be weak as well, and Setu Bandha Sarvangasana (Bridge Pose) is good for strengthening and teaching them to engage. Make sure to stretch the hip flexors, strongly lifting the tailbone while drawing the knees and ASISs in opposite directions. Maintaining these actions, lift one foot just a few inches off the floor; when you do this, the hamstrings in the standing leg will have to engage to help lift the pelvis and tailbone.