Coffee grounds contain nitrogen, which is beneficial for plants. Mulching with the grounds releases this nitrogen into the soil. The grounds also smell good, stay in one place and present an attractive appearance -- all hallmarks of the best mulches.
Unlike some other kinds of organic waste, coffee grounds break down readily when added to compost piles. If they are added when still a bit wet -- after the morning pot of coffee, for example -- they also contribute valuable moisture to the mix.
Using coffee grounds around slug-plagued plants like hostas is an effective deterrent to the destructive pests. The caffeine in the grounds is toxic for slugs and the physical barrier of the grounds bars access to the plants.