In order to solve the problem of high storage overhead in image data processing of the conventional image sensor, the invention provides an image data processing method and an image data processing device for an image sensor. The image data processing method comprises the following steps of: a, acquiring image information in a row scanning and sampling mode, and caching the image information by using a row as a unit; b, when the predetermined conditions are met, suspending the acquisition of the image information, and compressing the cached image information; and c, after the compression is finished, outputting the compressed image information, recovering the acquisition of the image information, and repeating the steps a, b and c. In the invention, the image data processing device only needs to cache the image information sampled and acquired before compression, and does not need to cache new image information during compression. Therefore, the requirement for the storage capacity of a cache module is greatly reduced, and the image data processing cost can be effectively reduced.