Fortunately, the fix is relatively easy: use another cable.
There can be a number of reasons:
1. Not all micro USB cables are created equal. Some work, some don't. If you have collected a whole bunch of them (from tablets, mobile phones etcetera) you might be trying the wrong cable...2. The controller's battery is too low, and it will try to charge over USB. Depending on the cable and the USB port this may disturb USB communication. Thus sometimes a cable only works with a charged controller.3. The cable only works with the PS4. This is typically the case with longer cables. It might be related to voltage drop etcetera.4. In general, the shorter and thicker the cable, the bigger the chance it actually works.
Tip: mark the original PS4 cable and store it, so you always have something to come back to, to make sure the problem doesn't lie elsewhere.
Windows 10 Remote Play application
Unless you have driver issues the problem is, with a probability of 99%, your USB cable.
1. Start the PS4 Remote Play application without the controller connected.2. Plug in the controller. The on-screen message changes, and the lamp on the controller lights up.3. If it doesn't light up, try another cable. And thus, we come full circle :-)
(PS4 and) Long cables
Unfortunately, some PS4's seem to have trouble driving longer USB cables, especially when the second USB port is in use as well. Mine certainly does. (First model, second batch IIRC.)
Unplugging the USB drive improved things a little, adding a hub did not. I had to try quite a few cables before I found something which would work as an extension cord for my Logitech racing wheel.
Try to connect a controller to the end of a (longer) cable: the light will often flash once, yellow, and disappear again if there is a problem.