Stretching is somewhat of a personal thing, however there are a couple things to know. There are four different types of stretching, each with their own recommendations and hazards.
Static stretching - this is the "sit and reach" that most people think of when you say stretching. Done more to extend how far you can stretch, and is contraindicated on muscles that have not been warmed up yet. Also, static stretching done before workouts has been shown to decrease muscle response and strength.
Dynamic stretching - Active, moving stretches that mimic the activity about to be performed. Increasing height stretch kicks, light bag work, anything that raises the core temperature and engages the limbs and involves motions from what you are about to do.
Proprioceptive Neuromuscular Facilitation (PNF) stretching - This is a very intensive type of stretching, designed specifically to increase range of motion (ROM). Basically it is a partner assisted stretch, where they assist you into a stretch, hold for a short period, contract against the stretch for a short period then stretch deeper. The most common I've seen in martial arts is the laying on the back with an upraised leg being pushed towards the head. Can increase the risk of muscle tears, esp with untrained partners/individuals. Should only do once, maybe twice a week.
Ballistic stretching - This is the older lean and bounce/pulse type stretch. This has been not really banned, but frowned upon for a long time due to the high level of injury risk. The risk is that in the bounce, you active the tendon reflex (Think of what your knee does when you get it whacked by the doc with a hammer), and the muscle will suddenly contract while you are trying to stretch it out. However, there have been a few studies in the past 5-10 years that suggest ROM gains are higher with ballistic than static stretching.
So, what I would probably suggest before kata (And what I do before competitions) is jumping rope or similar for a few minutes, followed by some light shadow sparring and stretch kicks of various sorts. You aren't going to gain any extra reach with static stretches and may reduce your power. Figure out a routine that works for you.