An ammonia plant is disclosed, where ammonia purge gas (20), is sent to a cryogenic recovery unit, said recovery unit comprising means of cooling (102, 202, 302, 402, 502) and a high-pressure phase separator (103, 203, 303, 403, 503) operating at loop pressure; inside said unit the purge gas (20) is cooled to a cryogenic temperature, and a partial liquefaction of methane and argon is achieved; the high-pressure phase separator separates the cooled stream into a gaseous stream and a bottom liquid; the gaseous stream is reheated in a passage of a heat exchanger; the unit is then capable to export a gaseous stream (123, 223, 323, 423, 523) containing nitrogen and hydrogen at loop pressure, that can be reintroduced at the suction side of the circulator (4) of the loop.