Connectors for platfom IO and ESP32/STM32 based projects

Working on PlatformIO embedded projects with STM32 and ESP32. Hardware reliability depends on connector selection too. Firmware gets most attention, hardware connections often fail. I face intermittent sensor readings and power instability. Temporary jumper wires often reduce system reliability.
How do you choose connectors in PlatformIO projects? Do you standardize connectors early in design?
Looking for practical rules from experience.