If you have disc related back pain then this could be a reason why it can be worse in the morning when you wake up and is also the reason why flexing the lower back first thing in the morning may not be the ideal thing to do.
The best bet is to wait until you have been up and about for at least half an hour but preferably an hour before doing stretches. In his book, Low Back Disorders, Stuart McGill, suggests waiting at least 1-2 hours.
NOTE: If your job requires full bending of the spine, then it will also be beneficial to make sure you have moved around or gone for a walk before starting to help reduce the risk of potential injury or flare up.
Of course, If you have back pain, then it is important to have it assessed as different injuries usually require different stretches or require you to avoid different movements to avoid aggravation. If you have pain and would like to have it assessed, feel free to contact me (or your local health expert) to arrange a time to have looked at.
Your body will thank you for it.
References
Reilly, Tyrell and Troup (1984). Circadian variation in human stature, Chronobiology International
Stuart McGill, Low back Disorders, 3rd Edition