One particular blood pressure medication has been shown to increased risk of both squamous and basal cell cancer. Long term use of Hydrochlorothiazide, (which is a diuretic commonly used to treat hypertension) has been shown to significantly increase your risk of skin cancer. No other anti-hypertensive medications showed the same association. If you are at high risk for skin cancer and are taking hydrochlorothiazide speak to your doctor to see if there may be a better alternative for you.

Citation

Journal of the American Academy of Dermatology
Hydrochlorothiazide Use and Risk of Non-Melanoma Skin Cancer: A Nationwide Case-Control Study From Denmark
J Am Acad Dermatol 2017 Nov 30;[EPub Ahead of Print], S Arnspang, D Gaist, SA Johannesdottir Schmidt, LR Hölmich, S Friis, A Pottegård