The answer is yes, in some situations using coffee when gardening is not only acceptable but a good idea. There are some caveats, though. 

Using Leftover Coffee Grounds

Coffee grounds are a good source of nitrogen in your compost pile or when added directly to the soil in the garden. If added in fairly large amounts, they can raise the acidity level of the soil for acid-loving plants such as blueberries, azaleas, and rhododendrons. Coffee grounds sprinkled over the ground around acid-loving plants serve as a mild acid fertilizer for them. And worms seem to love them, either in your garden or outdoor compost pile or in a vermicompost bin. And coffee grounds are regarded as an effective natural deterrent to garden pests such as slugs, snails, and ants. Rumors of coffee grounds repelling deer may be overstated. Deer are voracious eaters, and a few cups of coffee grounds are unlikely to make much of a difference. Coffee grounds will discourage a mischievous cat from roaming in your garden, but its effectiveness on rabbits and other common garden rodents is unknown.

How to Use Leftover Liquid Coffee

If you brew coffee by the pot, you may wonder if the cold leftovers can be used to water plants. Or, can the remaining half cup of cold coffee in your mug be poured into that potted pothos plant next to your desk? The short answer is: maybe. It depends on the plant. Plants that prefer more acidic soil (such as African violets, Impatiens, Norfolk Island pines, Phalaenopsis orchids, and Dieffenbachia) seem to respond well to a weekly watering with coffee. Outdoors, acid-loving plants like azaleas, Rhododendron, Siberian iris, lupine, and any pine trees or shrubs will do fine if periodically watered with cold coffee. Liquid coffee can also be used to water a compost pile that has become too dry.  If you decide to try watering houseplants with coffee, keep a close eye on your plant. If the foliage starts yellowing or the tips of the leaves start turning brown, it’s a sign that the coffee is adding too much acidity to the soil. It’s not a bad idea to dilute your coffee with water, especially if you prefer your daily cup of java on the strong side. In some offices, the only “watering” plants received is from emptying leftover coffee into the soil, and they often do quite well.  One caveat: if you add cream, milk, or sugar to your coffee, don’t pour it into your plants. Ditto for flavored coffees. The sugars and fats can not only harm your plants and invite pests but can eventually result in a stinky mess. A plant watered with sweetened or flavored coffee may soon be overrun by fungal gnats or odorous house ants.