Tyrosine kinase 2 (TYK2) is a nonreceptor tyrosine kinase that belongs to the JAK family also comprising JAK1, JAK2, and JAK3. TYK2 is an attractive target for various autoimmune diseases as it regulates signal transduction downstream of IL-23 and IL-12 receptors. Selective TYK2 inhibition offers a differentiated clinical profile compared to currently approved JAK inhibitors. However, selectivity for TYK2 versus other JAK family members has been difficult to achieve with small molecules that inhibit the catalytically active kinase domain. Successful targeting of the TYK2 pseudokinase domain as a strategy to achieve isoform selectivity was recently exemplified with deucravacitinib. Described herein is the optimization of selective TYK2 inhibitors targeting the pseudokinase domain, resulting in the discovery of the clinical candidate ABBV-712 (21).