The process is used to liquefy a dry natural gas containing water and heavy hydrocarbons having more than five carbon atoms. The following steps are carried out: a) the dry natural gas is made to flow through a solid that adsorbs water so as to obtain a water-depleted natural gas and an adsorbent solid laden with water; b) the water-depleted natural gas is made to flow through a solid that adsorbs heavy hydrocarbons having at least five carbon atoms, so as to obtain a natural gas depleted in heavy hydrocarbons and an adsorbent solid laden with heavy hydrocarbons; c) the natural gas depleted in heavy hydrocarbons is liquefied at a pressure above 40 bar absolute so as to obtain a pressurized liquid natural gas; and d) the pressurized liquid natural gas obtained in step c) is expanded down to atmospheric pressure so as to obtain a liquid natural gas and a gaseous fraction.