There has so far not been a single identified cause for grass eating in dogs, rather there are myriad contributing factors to this behaviour, some harmless and some destructive.
Some dogs will turn to grass eating to induce vomiting, eating it quickly and expelling shortly after. In this case, grass eating should be discouraged, as it is important to instead see a veterinarian to discover the underlying cause of and prevention of the stomach upset.
Some dogs chew grass to just savour the flavour, a fairly harmless practice when done in moderation in a safe environment. Dogs that do it for the enjoyment generally don't vomit afterward. Keep in mind that this behaviour should only be permitted in environments where the safety of the dog can be guaranteed, where there is no risk of ingestion of pesticides, herbicides or fecal matter of other animals, which can lead to the spread of disease.
If dogs are missing some essential nutrients in their diet they may turn to other sources. If not enough fibre is present in a dog's diet they may attempt to fill the void with grass to aid in healthy digestion. Review your dogs diet with your vet to ensure that it is well-balanced and they are receiving all of their essential nutrients.
If you need to put an end to grass eating there are options available to you make the transition easy and low-stress for both you and your pet.
Understand whether your dog is especially food-oriented or attention-oriented and make this the reward for the desired behaviour of leaving the grass alone.
Remain with the dog while they do their business or play, while you are ready to distract and reward with treats when a dog considers eating grass. While on a walk, use the "heel" command if it is in your dog's repertoire, which will bring them back to attention at your side should they stray to eat grass.
If you're not sure why your dog is eating grass and would like to find out if it could be a sign of an underlying condition, book an appointment with your local veterinarian today.