The best way to attract any wildlife species is to provide a consistent source of food, water, shelter, and habitat landscaping in an environment free of pesticides, herbicides, and other chemicals. In designing a butterfly habitat, you will want to provide a source of food for both caterpillars and butterflies.
Butterfly caterpillars can be found nibbling on the leaves of Asters, Milkweed, Snapdragons, Sunflowers, Violets, and Citrus. Not to worry…although they are eating the leaves of these plants, they will not cause any significant damage and will not move on to your prized roses or rhododendrons. Just keep in mind that without these crawling critters, the butterflies would not be possible.
When the butterflies become adults, they can be found sipping the nectar of flowering plants. Some research suggests planting the following flowers: Black-eyed Susan (Rudbeckia); Joe-pye weed (Eupatorium); Aster; Purple coneflower; Butterfly bush (Buddleia); Liatris.
Another source suggests honeysuckle, clover, phlox, wildflowers, rotting fruit (bananas, apples), molasses, and stale beer. Many species like to drink at mud puddles and congregate where the ground is damp and sunny. They recommend sinking a dish of damp sand in the ground with flat rocks around it to absorb heat.
Adult butterflies may use the butterfly house as shelter from the elements or for roosting at night, or it may be used as a nursery for the developing chrysalis. It may also be used by overwintering species as a hibernaculum.