How long is too long for a USB cable?

If you can, it's always best to reposition your devices so you don't need to exceed a USB cable's length limits, but that's not always possible. In those cases, you can purchase an active USB cable or an active USB extender, either of which will have built-in components to extend the signal's range. However, active USB cables are significantly more expensive than standard cables. They also draw extra power from the USB port, and thus might not be compatible with older ports.

Another potential solution is to use a powered USB hub and use the longest supported cable between the hub and your computer. Plugging too many devices into the same hub can slow them down, but as long as you don't exceed the USB port's bandwidth, you shouldn't encounter any noticeable performance difference. Powered hubs are preferable, since an unpowered hub can only draw power from the USB port, which can be unreliable.