It does not really matter, as long as you are properly warmed up before stretching. Never stretch a cold muscle! Massage increases blood flow, but you can also warm up your muscles yourself.
For a general fitness program, the American College of Sports Medicine recommends static stretching for most individuals that is preceded by an active warm-up, at least 2 to 3 days per week. (1)
Temporary, short term increase in flexibility is typical after massage or warm-up. Also, people are generally less flexible in the morning than later in the day. However, these short-term changes do not seem to make a difference in the long term:
Those who stretched in the evening did not have greater gains in ROM following a six week stretching protocol than those who stretched in the morning group. (2)
For long term flexibility gains, what matters is consistency and good form. It does not matter, whether you feel relatively tighter or more flexible during the stretching sessions. On average, your flexibility will increase in the same way in absolute terms.