It depends of course, might not have to tell anyone anything...
If not on a flight plan, just head off to where you're now going, and simply call up "inbound" when you get close.
If already talking to anyone, tell them where you're now going and when you're leaving frequency as already mentioned...
If on a flightplan, even if you're for some reason not already talking to someone, need to call somebody up to revise your destination and ETA.
If in controlled airspace, need to request a new clearance to somewhere else, and that takes care of the flight plan revision as well (except maybe in the US? not sure!).