I like this Molex NanoFit system for board headers and cables. They’re supposed to be assembled with a $600 crimping tool, or by machine, but they can be hand-soldered, with some practice.
Part numbers:
Molex NanoFit, available at Mouser, Digikey, etc.
(2) 3-Pin board header 105309-1203
(1) 2-Pin board header 105309-1202
(2) 3-Pin plug housing 105307-1203
(1) 2-Pin plug housing 105307-1203
(8) NanoFit crimp terminal 105300-2200 (You may have to buy at least Qty100.)
You can re-use the original 22AWG wire, or replace with 22 or 20AWG stranded wire. (There is no benefit in thicker wire.)
Strip a very short piece of insulation off the wires and tin it. (Apply extra flux paste if the wire is corroded with age.)

Cut off the top half of these little pieces of metal on the terminal. This part is normally folded over and crimped by the tool. We will be putting a blob of solder here instead.

Hold the pin vertically with an alligator clip—so that solder does not flow by gravity into the mating surfaces—and apply a little blob of solder to the spot.

Melt the wire into the spot.

And crimp the collar thingy around the wire.


Observe the order of pins on the old plug and the new, and insert the wires until they make a satisfying CLICK!

Unfortunately, the NanoFit connectors don’t have a mark to identify Pin1, so make sure you observe the position of the key, and get the wires in the same order.
Nice!

Finally, clip off this little locating pin on the NanoFit board header.

And install to your board. Make sure the key lines up with the board markings for the JST header. (Dashed lines)


