If you see your GP or midwife because of vaginal bleeding or other symptoms of miscarriage, you may be referred to an early pregnancy unit at a hospital for tests.
If you're more than 18 weeks pregnant, you'll usually be referred to the maternity unit at the hospital.
If you're less than 6 weeks pregnant, you may not be referred for tests straight away. This is because it's very hard to confirm a miscarriage this early on.
The hospital can carry out tests to confirm whether you're having a miscarriage. The tests can also confirm whether there's still some pregnancy tissue left in your womb (an incomplete or delayed miscarriage) or if all the pregnancy tissue has been passed out of your womb (a complete miscarriage).
The first test used is usually an ultrasound scan to check the development of your baby and look for a heartbeat. In most cases, this is usually carried out using a small probe inserted into the vagina (transvaginal ultrasound). This can feel a little uncomfortable but is not painful.
You may be able to have an external scan through your tummy if you prefer, although this method reduces the accuracy of the scan. Neither type of scan is dangerous to the baby and they do not increase your risk of miscarriage.
You may also be offered blood tests to measure hormones associated with pregnancy. You usually need to have 2 blood tests 48 hours apart to see if your hormone levels go up or down.
Sometimes a miscarriage cannot be confirmed immediately using ultrasound or blood testing. If this is the case, you may be advised to have the tests again in 1 or 2 weeks.
If you've had 3 or more miscarriages in a row (recurrent miscarriages), further tests are often used to check for any underlying cause. However, no cause is found in about half of cases. These further tests are outlined below.
If you become pregnant, most units offer an early ultrasound scan and follow-up in the early stages to reassure and support parents.
If you've had a third miscarriage, it's recommended that the foetus is tested for abnormalities in the chromosomes (blocks of DNA).
If a genetic abnormality is found, you and your partner can also be tested for abnormalities with your chromosomes that could be causing the problem. This type of testing is known as karyotyping.
If karyotyping detects problems with your or your partner's chromosomes, you can be referred to a clinical geneticist (gene expert).
They'll be able to explain your chances of a successful pregnancy in the future and whether there are any fertility treatments, such as in vitro fertilisation (IVF), that you could try. This type of advice is known as genetic counselling.
Read more about genetic testing and counselling.
A transvaginal ultrasound can be used to check the structure of your womb for any abnormalities. A second procedure may be used with a 3D ultrasound scanner to study your lower tummy and pelvis to provide a more accurate diagnosis.
The scan can also check if you have a weakened cervix. This test can usually only be carried out when you become pregnant again, in which case you'll usually be asked to come for a scan when you are between 10 and 12 weeks pregnant.
Your blood can be checked for high levels of the antiphospholipid (aPL) antibody and lupus anticoagulant. This test should be done twice, a few weeks apart, when you're not pregnant.
These aPL antibodies are known to increase the chance of blood clots and change the way the placenta attaches. These blood clots and changes can reduce the blood supply to the foetus, which can cause a miscarriage.
Sometimes a miscarriage is diagnosed during a routine scan carried out as part of your antenatal care. A scan may reveal your baby has no heartbeat or that your baby is too small for the date of your pregnancy. This is called a missed or delayed miscarriage.