A process for the treatment of a gasoline containing sulphur-containing compounds, olefins and diolefins, comprising the following steps: a) fractionating the gasoline into at least: • a light gasoline cut LCN; • a primary intermediate gasoline cut, MCN; and • a primary heavy gasoline cut HHCN; b) desulphurizing the primary intermediate gasoline cut MCN alone and in the presence of a hydrodesulphurization catalyst and hydrogen, at a temperature in the range 160°C to 450°C, at a pressure in the range 0.5 to 8 MPa, with a liquid space velocity in the range 0.5 to 20 h -1 and with a ratio between the flow rate of hydrogen, expressed in normal m 3 per hour, and the flow rate of feed to be treated, expressed in m 3 per hour under standard conditions, in the range 50 Nm 3 /m 3 to 1000 Nm 3 /m 3 in a manner such as to produce an at least partially desulphurized primary intermediate gasoline cut MCN; c) desulphurizing the primary heavy gasoline cut HHCN alone and in the presence of a hydrodesulphurization catalyst and hydrogen, at a temperature in the range 200°C to 450°C, at a pressure in the range 0.5 to 8 MPa, with a liquid space velocity in the range 0.5 to 20 h -1 and with a ratio between the flow rate of hydrogen, expressed in normal m 3 per hour, and the flow rate of feed to be treated, expressed in m 3 per hour under standard conditions, in the range 50 Nm 3 /m 3 to 1000 Nm 3 /m 3 in a manner such as to produce an at least partially desulphurized primary heavy gasoline cut HHCN; d) sending, as a mixture, the partially desulphurized primary intermediate gasoline cut MCN which has not undergone treatment following step b) and the partially desulphurized primary heavy cut HHCN which has not undergone treatment following step c) to a separation column in order to separate a gaseous stream containing hydrogen and H 2 S, a secondary intermediate gasoline cut MCN with low sulphur and mercaptans contents and a secondary heavy gasoline cut HHCN containing sulphur-containing compounds including recombinant mercaptans; e) desulphurizing the secondary heavy gasoline cut HHCN obtained from step d) containing sulphur-containing compounds including recombinant mercaptans in the presence of a hydrodesulphurization catalyst and hydrogen, at a temperature in the range 200°C to 450°C, at a pressure in the range 0.5 to 8 MPa, with a liquid space velocity in the range 0.5 to 20 h -1 and with a ratio between the flow rate of hydrogen, expressed in normal m 3 per hour, and the flow rate of feed to be treated, expressed in m 3 per hour under standard conditions, in the range 50 Nm 3 /m 3 to 1000 Nm 3 /m 3. a) fractionating the gasoline into at least: • a light gasoline cut LCN; • a primary intermediate gasoline cut, MCN; and • a primary heavy gasoline cut HHCN; • a light gasoline cut LCN; • a primary intermediate gasoline cut, MCN; and • a primary heavy gasoline cut HHCN; b) desulphurizing the primary intermediate gasoline cut MCN alone and in the presence of a hydrodesulphurization catalyst and hydrogen, at a temperature in the range 160°C to 450°C, at a pressure in the range 0.5 to 8 MPa, with a liquid space velocity in the range 0.5 to 20 h -1 and with a ratio between the flow rate of hydrogen, expressed in normal m 3 per hour, and the flow rate of feed to be treated, expressed in m 3 per hour under standard conditions, in the range 50 Nm 3 /m 3 to 1000 Nm 3 /m 3 in a manner such as to produce an at least partially desulphurized primary intermediate gasoline cut MCN; c) desulphurizing the primary heavy gasoline cut HHCN alone and in the presence of a hydrodesulphurization catalyst and hydrogen, at a temperature in the range 200°C to 450°C, at a pressure in the range 0.5 to 8 MPa, with a liquid space velocity in the range 0.5 to 20 h -1 and with a ratio between the flow rate of hydrogen, expressed in normal m 3 per hour, and the flow rate of feed to be treated, expressed in m 3 per hour under standard conditions, in the range 50 Nm 3 /m 3 to 1000 Nm 3 /m 3 in a manner such as to produce an at least partially desulphurized primary heavy gasoline cut HHCN; d) sending, as a mixture, the partially desulphurized primary intermediate gasoline cut MCN which has not undergone treatment following step b) and the partially desulphurized primary heavy cut HHCN which has not undergone treatment following step c) to a separation column in order to separate a gaseous stream containing hydrogen and H 2 S, a secondary intermediate gasoline cut MCN with low sulphur and mercaptans contents and a secondary heavy gasoline cut HHCN containing sulphur-containing compounds including recombinant mercaptans; e) desulphurizing the secondary heavy gasoline cut HHCN obtained from step d) containing sulphur-containing compounds including recombinant mercaptans in the presence of a hydrodesulphurization catalyst and hydrogen, at a temperature in the range 200°C to 450°C, at a pressure in the range 0.5 to 8 MPa, with a liquid space velocity in the range 0.5 to 20 h -1 and with a ratio between the flow rate of hydrogen, expressed in normal m 3 per hour, and the flow rate of feed to be treated, expressed in m 3 per hour under standard conditions, in the range 50 Nm 3 /m 3 to 1000 Nm 3 /m 3.