iftop is a handy utility on MacOS, Linux and other Unices for a live Terminal graph of network data flow to particular addresses. On computers with many network interfaces, including virtual interfaces such as on MacOS, it is handy to set a default interface in a config file. iftop uses the file ~/.iftoprc.
For example, on MacOS you may be interested in interface “en1”.
To help determine the desired interface, use
ip a to find the interface with the public IP address.
Then create ~/.iftoprc containing like:
where “en1” is your desired interface determined as per above.