1. A method for reading a barcode by means of an optical reader arranged to capture at a determined sampling frequency a series of partial images of the barcode by a sensor having at least one line of pixels, wherein the barcode consists of a plurality of bars of variable widths that define a bit sequence, and wherein this method has the following steps: A) the sensor is moved along the barcode parallel to said line of pixels at any speed of movement less than a maximum speed, wherein this maximum speed is defined so that the shift between two consecutive partial images is less than the width (X un ) of the image of a bar unit of said barcode; B) the length (of said line of pixels is less than the length of the theoretical image of the barcode at the sensor and more than the width of the image of a bar of maximum width on the sensor; C) for each partial image captured by the sensor a logical value is determined by the level of light intensity received by at least one pixel located more or less in the centre of said line of pixels; D) for each partial image captured by the sensor the width of the bar corresponding to said logical value, when this is defined, is measured when this bar is incorporated completely into this partial image; E) when the same logical value is obtained for two consecutive partial images in step C), a single logical value and the width of the corresponding bar are retained to establish said bit sequence.