While the ports look the same, the technologies have a number of key differences between Thunderbolt 3, USB-C 3.1 Gen 2, and USB-C 3.1 Gen 1.
The problem is that the port and cable connectors for all three technologies look the same, and the only difference is the labeling (or, on some devices, the lack thereof). D Type HDMI
Must read: Speed up your iPhone by clearing the RAM
The main difference between the three technologies is bandwidth.
This difference in bandwidth means that Thunderbolt 3 has the capacity for more displays to be hooked up to it than USB-C 3.1:
The greater bandwidth also means that Thunderbolt 3 can support external GPUs (eGPUs), something that isn't an option for USB-C 3.1.
Thunderbolt 3 also allows up to six devices to be daisy-chained together, while USB-C 3.1 doesn't support daisy-chaining.
Well-labeled ports on OWC's Thunderbolt 3 dock
When it comes to compatibility, Thunderbolt 3 is backward compatible with earlier Thunderbolt 2 and Thunderbolt devices, USB-C 3.1 devices, and USB 3.x and 2.x devices, as long as you have the right adapter. USB-C 3.1 works with USB 3.x and 2.x devices, but doesn't support Thunderbolt devices.
When it comes to cables, Thunderbolt 3 cables can be identified by the logo (hopefully) printed on the connector.
Micro Hdmi Type D Thunderbolt 3 logo on cable connector