With insomnia, it all basically boils down to endocrine system imbalances. Sleep is a physiological function that is controlled by hormones, and these hormones are of course released by endocrine system glands according to a natural cycle. A person who is having trouble sleeping is merely experiencing a disruption in this natural cycle.
To answer this question, it is helpful to look at what promotes healthy sleep cycles in the first place. Perhaps the single most important influencing factor in setting these cycles is exposure to natural sunlight. In fact, simply getting natural sunlight during the day often corrects the problem outright. I know it sounds simple, but exposure to sunlight is fundamental to healthy sleep cycles.
A lot of this, of course, has to do with the production and suppression of melatonin, which is also called the sleep hormone. Melatonin levels normally rise at night, and peak during sleep. Once a person wakes up and goes outside to get natural sunlight exposure, melatonin levels are suppressed. This tells the body that daylight is here, and that we should be awake and alert during the day.
But when a person avoids sunlight -- if they have an office job and only get fluorescent light or other forms of artificial light during the day -- these melatonin levels are not suppressed during the day. They remain unnaturally high, and this tells the body that it may still be night. This is why a lot of people tend to feel drowsy during the day or have a lack of energy, and subsequently, they can't sleep at night either. It's all due to the unnaturally high levels of melatonin during the day which cause unnaturally low levels at night time as well.
So once again, the most effective strategy is to get sunlight --- to suppress those melatonin levels during the day and let them come back strong at night. If you live in a climate where you can't get a lot of natural sunlight, you can help yourself through the use of light boxes. However, light boxes are not a replacement for natural sunlight. In fact, nothing comes close to the intensity of light you receive from the sun. Even high-powered light boxes only provide a fraction of the light energy of natural sunlight. So make sure you get natural sunlight on your skin. And by the way, getting it through a window is not the same as getting it outdoors. Windows filter out ultraviolet light, so you have to expose your skin to direct sunlight.
(This is why many of the kings and queens in European history went mad, by the way: they wanted to keep their skin pale by avoiding sunlight. Nearly all royals were chronically deficient in vitamin D -- and that causes schizophrenia, depression, aggression and other mental disorders...)
There could be other problems causing insomnia as well. You might have low melatonin production. Maybe you're getting sunlight during the day, but at night your body isn't producing melatonin in the way that it should. A shortcut to solving this is to take melatonin supplements. These are available at health food stores or vitamin shops online. Melatonin supplements should be taken an hour or so before bedtime, and they will typically help people sleep more soundly.
But understand this is just a stop-gap measure. If your body isn't producing melatonin, there's something imbalanced in your system, and you need to get back to the fundamentals of health in order to recreate an environment in which your body will naturally produce the required levels of melatonin that support healthy, sound sleep.