Treating insomnia 

The first step in treating insomnia is to find out whether the problem is being caused by an underlying medical condition.

If it is, once the condition has been treated, your insomnia may disappear without the need for further medical help.

Good sleep hygiene

Your GP will be able to advise you about what you can do at home to help you sleep. This is known as good sleep hygiene and includes:

  • establishing fixed times for going to bed and waking up (try to avoid sleeping in after a poor night's sleep)
  • trying to relax before going to bed
  • maintaining a comfortable sleeping environment (not too hot, cold, noisy or bright)
  • avoiding napping during the day
  • avoiding caffeine, nicotine and alcohol late at night 
  • avoiding exercise within four hours of bedtime (although exercise in the middle of the day is beneficial)
  • avoiding eating a heavy meal late at night
  • avoiding watching or checking the clock throughout the night
  • only using the bedroom for sleeping and sex

Read more simple methods that may help prevent insomnia.

If you have long-term insomnia (lasting more than four weeks) your GP may: 

  • recommend cognitive and behavioural treatments
  • prescribe a short course of sleeping tablets for immediate relief or to manage a particularly bad period of insomnia; however, they aren't recommended for long-term use 

Cognitive and behavioural treatments

The aim of cognitive behavioural therapy for insomnia (CBT-I) is to change unhelpful thoughts and behaviours that may be contributing to your insomnia. It may be recommended if you've had sleep problems for more than four weeks.

CBT-I can include:

  • stimulus-control therapy - which aims to help you associate the bedroom with sleep and establish a consistent sleep/wake pattern
  • sleep restriction therapy - limiting the amount of time spent in bed to the actual amount of time spent asleep, creating mild sleep deprivation; sleep time is then increased as your sleeping improves
  • relaxation training - aims to reduce tension or minimise intrusive thoughts that may be interfering with sleep
  • paradoxical intention - you try to stay awake and avoid any intention of falling asleep; it's only used if you have trouble getting to sleep, but not maintaining sleep
  • biofeedback - sensors connected to a machine are placed on your body to measure your body’s responses, such as muscle tension and heart rate; the machine produces pictures or sounds to help you control your breathing and body responses

CBT-I is sometimes carried out by a specially trained GP. Alternatively, you may be referred to a clinical psychologist.

You'll usually have four or five sessions of CBT-I, each lasting about an hour. As part of the treatment you may be asked to keep a daily record of your sleep (a sleep diary).

In the UK, there are a number of places that provide specialist sleep services such as CBT-I. These include:

The website of the British Sleep Society (BSS) also has a post code search that you can use to find your nearest sleep centre.

Sleeping tablets

Sleeping tablets (hypnotics) are medications that encourage sleep. They may be considered:

  • if your insomnia symptoms are very severe
  • to help ease short-term insomnia
  • if the good sleep hygiene and cognitive and behavioural treatments mentioned above prove ineffective 

However, doctors are usually reluctant to prescribe sleeping tablets because although they help relieve the symptoms of insomnia, they don't treat the cause.

If you have long-term insomnia, sleeping tablets are unlikely to help. Your doctor may consider referring you to a clinical psychologist to discuss other approaches to treatment.

Read more about why sleep medication only offers short-term relief.

You should be prescribed the smallest effective dose possible for the shortest time necessary (for no longer than a week). In some cases, you may be advised to only take the medication two or three nights a week, rather than every night.

Sleeping tablets can sometimes cause side effects, such as a feeling that you're hungover and daytime drowsiness.

It's best to take sleeping tablets at night, before you go to bed. Sometimes, particularly in older people, the hangover effects may last into the next day, so be cautious if it's likely that you'll be driving the next day (see below for more advice about driving).

It's very easy to become dependent on sleeping tablets, even after a short-term course. Therefore, if you're taking sleeping tablets regularly (every night), you should consider reducing them or stopping them altogether. Speak to your GP for advice.

Short-acting benzodiazepines or the newer 'Z medicines' (see below) are the preferred medicines for insomnia and are only available on prescription.


Benzodiazepines are tranquillisers that can reduce anxiety and promote calmness, relaxation and sleep.

These medicines should only be considered if you have severe insomnia or it's causing extreme distress.

Benzodiazepines will make you feel sleepy and can lead to dependency. Therefore, only short-acting benzodiazepines (with short-lasting effects) should be used to treat insomnia. Temazepam is the benzodiazepine that's often prescribed.

Benzodiazepines can have many potential side effects. See the link to temazepam above for a full list of possible side effects.

Z medicines

Z medicines are a newer type of short-acting medicines that work in a similar way to benzodiazepines. They include: 

  • zaleplon
  • zolpidem
  • zopiclone


Zaleplon is licensed to treat people with insomnia who have difficulty falling asleep.

It should only be used at the lowest possible dose and for a maximum of up to two weeks.

Common side effects of zaleplon (affecting more than one in 100 people) include:

Less common side effects (affecting more than one in 1,000 people) include:

  • apathy (lack of interest)
  • balance and co-ordination problems
  • concentration problems
  • changed sense of smell
  • dizziness
  • hallucinations (seeing things that aren't real)

Read more about zaleplon.


Zolpidem is licensed for the short-term treatment of debilitating insomnia or where it's causing severe stress.

It should only be used at the lowest possible dose and for a maximum of up to four weeks.

Common side effects of zolpidem include:

Less common side effects include confusion and double vision.

Read more about zolpidem.


Zopiclone is licensed for the short-term treatment of insomnia including difficulty falling asleep, waking up during the night and long-term insomnia that's debilitating or causing severe distress.

It should only be used at the lowest possible dose and for a maximum of up to four weeks.

Common side effects of zopiclone include:

  • dry mouth 
  • metallic taste in your mouth
  • sleepiness

Less common side effects include:

  • dizziness, nausea and vomiting
  • drowsiness
  • headaches

Read more about zopiclone.

Z medicines can also sometimes cause psychiatric reactions, such as anger, irritability, agitation, aggressiveness, delusion, nightmares and hallucinations.

You should stop taking your medication and see your GP immediately if you experience any of these psychiatric reactions.

There's little difference between Z medicines and benzodiazepines. If one doesn't work, swapping to another is unlikely to have a different effect.

The National Institute for Health and Care Excellence (NICE) guidance contains more about the use of zaleplon, zolpidem and zopiclone for the short-term management of insomnia (PDF, 83.3kb).


Antidepressants are sometimes prescribed for people with insomnia, and can be particularly useful if a person also has a history of depression.

Melatonin (Circadin)

Medicines that contain melatonin have been shown to be effective in relieving insomnia for up to 26 weeks in elderly people.

Melatonin is a naturally occurring hormone that helps regulate the sleep cycle (known as the circadian rhythm).

Circadin is the only medicine containing melatonin. It's licensed to treat insomnia and is only available on prescription for people who are 55 years of age or over.

Circadin is designed as a short-term treatment for insomnia and shouldn't be taken for more than three weeks. It's not recommended for people with a history of kidney disease or liver disease.

Side effects of Circadin are uncommon but can include:

If you're finding these side effects troublesome, stop taking Circadin and contact your GP.


If you have insomnia, it may affect your ability to drive. Medical conditions that cause sleepiness should be reported to the Driver & Vehicle Licensing Agency (DVLA).

GOV.UK has more information about telling the DVLA about a medical condition or disability.

Complementary and alternative therapies

There's very limited evidence to suggest that either acupuncture or hypnotherapy are effective for treating insomnia.

Certain herbal remedies, such as chamomile and passionflower, have been reported to have positive effects. However, they haven't been thoroughly clinically tested, so their effectiveness and long-term safety is unknown.

Page last reviewed: 09/12/2013

Next review due: 09/12/2015