Carbonic anhydrases (CAs) IX and XII are crucial for the survival and metastasis of solid tumors under hypoxic conditions. We designed compounds 7a-s, integrating triazole and benzenesulfonamide scaffolds known for inhibiting tumor-associated CAs IX/XII. Initial synthesis included compounds 7a-e, followed by diversification with small hydrophobic groups (7f-m) and hydrophilic heterocyclic secondary amines (7n-s). Compounds were evaluated against CA II, IX, and XII to assess activity and selectivity. Chlorinated derivative 7l exhibited the highest efficacy against CA IX (KI = 0.317 μM) and ditrifluoromethylated 7j against CA XII (KI = 0.081 μM). Subsequent testing on 60 cancer cell lines at 10 μM revealed promising anticancer activity, especially for dimethylated derivative 7h (CA IX, KI = 1.324 μM; CA XII, KI = 0.435 μM), with GI50 values ranging from 0.361 to 9.21 μM. Molecular docking analyses elucidated binding mechanisms, highlighting potential inhibitory actions of compound 7h on CAs IX and XII.