Knowing that Wi-Fi on 2.4 GHz has a good signal strength when there are 50 m between the access point and the unit that transmits the data. I want to transmit this data over a distance of 1.5 Kilometers, there is a line of sight. What can I do to make the communication over 1.5 km as good as the communication over 50 m distance?
You want to increase the operating range to 3000%. (=x30). You have the following options:
increase the transmitting power to x 900 (=x30^2), in decibels about 30dB more.
use very narrow beam antenna, directivity about 30dB in one of your stations
use at both stations quite high directivity antennas, 15dB or more is needed.
The signal strenghtening caused by antenna directivity is said usually "antenna gain" because it affects like an amplifier in the transmitter. Term gain is the usual one and possibly increased losses due the more complex antenna structure are taken into the account, so the gain is usually a little less than the pure geometrical directivity.
I recommend antennas with 15dB or more gain at both ends. Antenna amplifier is useless, because antennas are not pure receiving antennas, they transmit, too.
NOTE: This all is illegal in some countries. because using narrow beam transmitting antennas you effectively create fields which are much stronger than your radio frequency usage license allows. It will be interpreted like having too strong transmitter. In this case the only option is to have repeater (=relay station) chain.
ADD due a comment: Obstacles between the antennas really can cause harm. Besides being literally in the way of the radio waves they also cause multipath propagation. The result: Strong variations in the signal strength, impossible to calculate beforehand and varying continuously (=fading). Even ground and water must be considered as obstacles if they are not far enough below the line between the antennas. Radio link designers try to keep at least the 1st Fresnel zone (=ellipsoid) clean to keep the fading in tolerable numbers. See the following article:
In your case the 1st Fresnel zone reaches about 5,4 meters below the line between the antennas. => You must have at least 5,4m high antenna towers if there's nothing else between the stations than plain uniform ground or water.