Reply promptly, and use their channel
The single kindest thing you can do is answer early through the same channel they used — reply to the RSVP, the text, or the email rather than letting it sit. A prompt no lets a host adjust counts, food, and seating while it still helps them; a slow one, or a silence they have to chase, is far more awkward than the decline itself. If you already know the answer, don't wait for the deadline to say so.
Say no clearly — don't leave a 'maybe' hanging
A soft 'maybe' that never resolves is harder on a host than a clean no, because they have to plan around a guest who may or may not appear. If you can't come, say so plainly and warmly: gratitude first, then a clear decline. It feels kinder in the moment to keep the door ajar, but a definite answer is the real courtesy — it lets everyone stop wondering and get on with the plans.
Keep the reason short, or skip it
You are never obligated to justify a no, and a paragraph of explanation can read as though you're asking to be talked out of it. A single line is plenty ('we'll be away that weekend'), or none at all. If you genuinely want to stay connected, an offer with a real intent behind it — 'can we grab coffee soon?' — lands warmly; if you don't mean it, leave it off rather than making a promise you won't keep.