I want to connect two PCBs with four wires: VCC, GND, 2x I2C. Which connector is best suited for this application? I was thinking about an USB connector (and wire), but I am not sure if that is the best possibility. Therefore I wanted to ask if there are better connector types than USB for this application? VCC is 5V.
Some I2C interfaces on the market (MCC iPort for instance) use AMP 4-1761206-1 connectors, for which pre-fabricated cables are readily available.
You could also go with RJ-11 if you're not worried about shielding (as long as no one connects your board to the PSTN...)
I use this type of flat cables. They are reliable to use.
My go-to solution for something like this is just female headers on the board, ribbon cable with male headers soldered on for the cable. I will often use an extra pin clipped off with the hole in the female header plugged with a piece of wire. This keeps me from plugging it in backward.