In this paper, we propose a new wavelet-based lossless image coder that is based on a state-of-theart algorithm, namely SPIHT (set partitioning in hierarchical trees). An algorithmic modification is introduced in order to increase its efficiency. This consists of adding a new test on direct descendants in the sets of type A to process the parent coefficients that are significant due to their nondirect descendants. Also, new sets of type C are defined to perform a separate sorting of the sets that have insignificant children. The idea behind the second proposition is to remove all tests over the entries (A, B and C) since the number of significant sets is much higher than that of insignificant sets. A number of experiments, carried out on various test images, demonstrates significant improvement over the conventional SPIHT for both greyscale and colour images.