Compounds that are inhibitors of the unfolded protein response and endonuclease IRE1 are provided, together with compositions comprising such compounds, and methods for their use in the treatment of various disorders, such as cancer, autoimmune disorders, and diabetes. Also provided are packaged pharmaceuticals comprising these compositions. The compositions may be administered in combination with another therapeutic agent.