It is native to western North America from British Columbia to California to the Rocky Mountains, where it grows in moist, partially shaded habitat in mountains, woodlands, chaparral, and other areas.