A system for measuring salinity at a bottom of a hydrocarbon well by means of a time domain reflectometry technique, comprising a waveguide or cable that is attached to a hydrocarbon production line to the bottom of the well, an electromagnetic pulse generator to send a test signal, an oscilloscope to measure the signal produced by the pulse generator and the signal reflected by the hydrocarbon at the bottom of the well, indicating the difference between the two signals, this difference indicating a salinity value of the hydrocarbon, a signal amplifier and a signal adapter to control the signal characteristics in order to obtain the best sharpness for greater accuracy of the measurement, and a computer to analyze the information, infer the salinity from the return signal through the waveguide and store the information.