Biological agents including anti-tumor necrosis factor (anti-TNF; adalimumab, infliximab, etanercept) and anti-interleukin-12/13 (IL12/23; ustekinumab) are essential for treatment of patients with severe psoriasis. However, a significant proportion of the patients do not respond to a specific treatment. Pharmacogenetics might be a way to predict treatment response. Using a candidate gene approach, 62 mainly functional single-nucleotide polymorphisms (SNPs) in 44 different genes were evaluated in 478 Danish patients with psoriasis undergoing 376 series of anti-TNF treatment and 230 series of ustekinumab treatment. Associations between genetic variants and treatment outcomes (drug survival and Psoriasis Area Severity Index reduction) were assessed using logistic regression analyses (crude and adjusted for gender, age, psoriatic arthritis and previous treatment). After correction for multiple testing controlling the false discovery rate, six SNPs (IL1B (rs1143623, rs1143627), LY96 (rs11465996), TLR2 (rs11938228, rs4696480) and TLR9 (rs352139)) were associated with response to anti-TNF treatment and 4 SNPs (IL1B (rs1143623, rs1143627), TIRAP (rs8177374) and TLR5 (rs5744174)) were associated with response to ustekinumab treatment (q < 0.20). The results suggest that genetic variants related to increased IL-1β levels may be unfavorable when treating psoriasis with either anti-TNF or ustekinumab, whereas genetic variants related to high interferon-γ levels may be favorable when treating psoriasis with ustekinumab.