Cancer is a complex disease caused by many different mechanisms. It is fair to say that we do not fully understand the cause of cancer. However, fundamentally, all cancer is a result of genetic damage to cells that ultimately leads to uncontrolled growth and cell division.

Genetic damage to the cells may occur due to exposure to cancer-causing substances called carcinogens. Exposure to carcinogens may occur through environmental pollution, chemicals at the workplace, infections, and lifestyle factors, among other factors.

Here is a list of common human carcinogens:
Alcohol
Arsenic
Asbestos
Benzene
Cadmium
Chlorambucil
Chromium (VI) compounds
Chinese liver fluke
Coal
Cyclophosphamide
Engine exhaust, diesel
Epstein-Barr virus (EBV)
Estrogen-containing hormone replacement therapy
Etoposide in combination with cisplatin and bleomycin
Formaldehyde
Helicobacter pylori (infection with)
Hepatitis B virus
Hepatitis C virus
Human immunodeficiency virus type 1 (HIV-1)
Human papillomavirus (HPV), some types
Human T-cell lymphotropic virus type I (HTLV-1)
Ionizing radiation
Human herpesvirus 8 (HHV-8)
Leather dust
Nickel compounds
Polychlorinated biphenyls (PCBs), some types
Processed meat
Tobacco
Ultraviolet (UV) radiation, including UVA, UVB, and UVC rays
Ultraviolet-emitting tanning devices

For a complete list of human carcinogens, please review the reference below.

Inherited susceptibilities that run in families, and are passed on from one generation to the next, are also responsible for causing human cancer. Inherited genetic factors cause about 5-10% of cancers. For example, carriers of the deleterious BRCA 1 gene are at a high lifetime risk of developing breast or ovarian cancer.

Lifestyle factors like obesity, lack of exercise, and drinking hot beverages may also increase the risk of cancer.

Finally, a large proportion of cancers is attributable to “bad luck,” or random mutations arising during DNA replication in primitive cells of the body called stem cells. In contrast to most differentiated (matured) cells, stem cells retain the ability to self-renew and evolve into many different types of cells. Although they constitute only a small percentage of cells in an organ, stem cells are critical for the body’s ability of self-renewal and maintenance. In a landmark paper in the journal Science, it was hypothesized that the lifetime risk of cancer in a particular organ is strongly correlated with the number of stem cell divisions in the organ. The “bad luck” hypothesis can also be used to explain the differences in cancer incidence between different cancers that share a common causative factor. For example, sun exposure is a risk factor for both basal cell cancer and melanoma; yet the incidence of melanoma is much lower than basal cell cancer, probably because of a lower rate of stem cell division in melanocytes.

On a positive note, however, it is estimated that lifestyle modification can significantly reduce the risk of developing cancer and dying from cancer. For example, approximately 80% to 90% of lung cancer deaths could be avoided by lifestyle modification, primarily smoking cessation. Although we cannot choose our “luck,” we can certainly choose our lifestyle.

References:
https://monographs.iarc.fr
https://www.ncbi.nlm.nih.gov/pubmed/25554788