X-rays are a type of radiation that can pass through the body and is absorbed at different rates by different parts of the body. A detector on the other side of the x-ray machine picks up the x-rays after they have passed through the body and turns them into an image. X-rays are carried out by trained specialists called radiographers.
During the procedure, the part of your body examined will be exposed to a low level of radiation for a fraction of second. The amount of radiation you are exposed during an x-ray is equivalent to between a few days and a few years of exposure to natural radiation from the environment. It has less than one in 1 million chance of causing cancer in the long term. It is better to discuss with your doctors with regards to the benefits and risks of having an x-ray before having one.