Typical habitat is along trails and roadsides, embankments, hillsides, stone- and gravel-laid paths and roads, meadows, young woodlands, sparse forest, woodland edges, and clearings. Often plants can be found where they do not get sufficient light to form fruit. In the southern part of its range, it can grow only in shady areas; further north it tolerates more sun. It is tolerant of a variety of moisture levels (except very wet or dry conditions). It can survive mild fires and/or establish itself after fires.