Not only do butterflies need food but they need a place to lay eggs and have food for the larva. So we have made a garden just for that...plus some sunflowers thrown in for fun.
First, find out what type of food butterfly larva in your area need. This book here "Beginner's Guide to Butterflies" By Donald and Lillian Stokes list them. For us we have allot of swallow tail. So we are planting Dill and fennel (they also like parsley) and some short Sun flowers. And a good night time read is "The Hungry Caterpillar." Add a really cute helper with a big hat...just for some fun.
These are some pots we bought a few years ago that the kids painted then stamped. We replaced the soil and sprinkled some seed starter soil on top...about an inch. The kids drew a circle in the middle and that is where they planted the sunflowers.
Each of my kids are very different gardeners, one wants to get it done and onto the next and the other looks for perfection. Trinity just sprinkled the dill and fennel all around. Alex divided up the soil and very carefully placed his seeds. Two very different gardeners showing how really opposite they are.