Cancer has predominant environmental and somatic causes but the assessment of hereditary (genetic) causes is difficult, except for highly penetrant single-gene causes. Family studies are only partially informative in this regard because family members share diet and life-styles. Twin studies have been classically used to disentangle the effects of heredity and environment on disease etiology. We estimate the genetic and environmental components in colorectal and lung cancer and melanoma by comparing cancer risks in family members. The Swedish Family-Cancer Database, comprising more than 6 million individuals, was used as the source of family and cancer data. Tetrachoric correlations were used to describe similarity in cancer liability among family members. Structural equation modelling was used to derive estimates of the importance of genetic and environmental effects. The estimated genetic component ranged from 10% in colon and colorectal cancer to 18% in melanoma. For lung cancer, the share was 14%. If assortative mating were important for liability to cancer, these heritability estimates may be an underestimation of the true genetic effects. Non-shared environmental effect was 67-68% in colorectal cancer and melanoma, and 71% in lung cancer. Shared and childhood environments were equally important in colorectal cancer and melanoma, whereas no childhood effect was observed for lung cancer.