There are a couple of issues......
The first is the caffeine, the second is what you put in it (full fat milk, sugars etc)
I actually rely on coffee to give me a boost every now and again and I am partial to a nice cup of tea, therefore I don't restrict their intake. I will probably have 2-3 cups of each a day.
However, I do also drink 4 litres+ of water a day.
And yes I go to the toilet a lot.
Caffiene can dehydrate you. A good indicator is the colour of your piss. You want it to be as clear as possible. If its dark yellow then you are severly dehydrated.
Paul.