A versatile tool for electrochemical fabrication of heteronanojunctions with nanocontacts made of a few atoms and nanogaps of molecular spacing is presented. By integrating microfluidic circuitry in a lab-on-chip approach, we keep control of the electrochemical environment in the vicinity of the nanojunction and add new versatility for exchanging and controlling the junction's medium. Nanocontacts made of various materials by successive local controlled depositions are demonstrated, with electrical properties revealing sizes reaching a few atoms only. Investigations on benchmark molecular electronics material, trapped between electrodes, reveal the possibility to create nanogaps of size matching those of molecules. We illustrate the interest of a microfluidic approach by showing that exposure of a fabricated molecular junction to controlled high solvent flows can be used as a reliability criterion for the presence of molecular entities in a gap.