Double layers (DLs) have been observed in a plasma reactor composed of a source chamber attached to a larger expanding chamber. Positive ion beams generated across the DL were characterized in the low plasma potential region using retarding field energy analyzers. In electropositive gases, DLs were formed at very low pressures (between 0.1 and 1 mTorr) with the plasma expansion forced by a strongly diverging magnetic field. The DL remains static, robust to changes in boundary conditions, and its position is related to the magnetic field lines. The voltage drop across the DL increases with decreasing pressure, i.e. with increasing electron temperature (around 20 V at 0.17 mTorr). DLs were also observed in electronegative gases without a magnetic field over a greater range of pressure (0.5 to 10 mTorr). The actual profile of the electronegative DL is very sensitive to external parameters and intrusive elements, and they propagate at high negative ion fraction. Electrostatic probes measurements and laser induced photodetachment show discontinuities in all plasma parameters (electron density, electron temperature, negative ion fraction) at the DL position. The voltage drop across the electronegative DL is about 8 V, is independent of the gas pressure and therefore of the electron temperature.