Coffee dehydrates you, so for every cup you should drink an extra glass of water to make up for it. It is repeated by personal trainers, wellness blogs, and helpful colleagues, and it sounds sensible because caffeine makes you need the toilet. Net loss, surely.
Moderate coffee hydrates you on balance, because the water in the cup more than covers caffeine's mild diuretic effect. Caffeine does nudge your kidneys to pass a bit more urine, but the effect is small at normal intakes, and habitual coffee drinkers develop a tolerance to even that. When researchers have actually measured hydration in people drinking moderate amounts of coffee versus water, they found no meaningful difference in overall hydration; the coffee counted toward fluid intake just fine. The 'extra glass of water per coffee' rule is not based on the evidence. Very large doses of caffeine, or coffee in someone not used to it, can have a bigger diuretic effect, so it is not infinite, but a few cups a day for a regular drinker is a net positive for your fluid levels. So your morning long black is not a hydration debt you have to repay. It is, mostly, a cup of water that happens to be brown and keeps you upright.