Building and maintaining a compost pile is a rewarding and organic move for enriching your soil and garden, and all summer long you've got free material to add: the grass clippings from your own yard, or a neighbor's.
Use a mulching blade on your lawnmower to ensure that the grass is cut into tiny pieces; it will decompose at a faster rate. Some lawnmowers are "mulching mowers" but almost all lawnmowers can be equipped with a mulching blade, which is designed to cut the grass finely.
Allow the grass to dry before moving it to the compost pile. Wet, soggy grass will only rot and stink. If the layer of grass is light, simply leave it on your lawn for a day or so in the sunshine. If you have a thick layer, use a rake to spread it out so that it can dry.
Spread the dried grass clippings in a 4-inch layer on the compost; add a layer of other, carbon-rich material such as dried leaf mulch, shredded paper, straw or garden debris before adding another layer of grass clippings.