Taken from:
guinea pig corner
Hay:
Guinea pigs need a constant supply of fresh, clean hay to aid digestion and keep their teeth short.
Hay forms an essential part of your guinea pigs' diet; without it they can quickly become ill. Guinea pigs like to chew on hay all day long, around the clock, so it's essential that you provide them with a constant supply of clean, fresh hay.
Feeding your guinea pigs hay has numerous advantages. Perhaps most importantly it helps them regulate digestion, ensuring that their food is processed properly. Without it, your cavies can develop stomach problems such as diarrhea.
Hay is quite abbrassive, and helps your pigs to keep their teeth ground down to a comfortable length. Unlike humans, guinea pigs' teeth grow constantly, and without a way to keep them short, they can grow too big for their mouth, making eating difficult and painful.
Grass:
Fresh grass is less important than hay, but contains several important vitamins and minerals, and so is an excellent addition to their diet when available.
Fresh grass contains lots of vitamin C, and guinea pigs seem to love it, so it is well worth providing some if possible. It is most nutritious in the spring and summer, but contains few nutrients in the winter, so treat it as a seasonal supplement to their diet.
If you have access to a good supply of fresh grass, you should feed it to your pigs daily. Be careful when giving them grass from a meadow, as it may have been sprayed with dangerous herbicides. You should never give your guinea pigs grass which has been cut with a lawn mower - always pull it out by hand.
Grass begins to rot very quickly, so don't leave it in your pigs' cage for more than an hour or two. Whatever they haven't eaten in that time should be removed and thrown away.