Contrast is a distinctive image feature that tells if it has adequate visual quality or not. On many occasions, images are captured with low-contrast due to inevitable obstacles. Therefore, an improved type-II fuzzy set-based algorithm is developed to enhance the contrast of various color and grayscale images properly while preserving the brightness and providing natural colors. The proposed algorithm utilizes new upper and lower ranges, amended Hamacher t-conorm, and a transform-based gamma correction method to provide the enhanced images. The proposed algorithm is assessed with artificial and real contrast distorted images, compared with twelve specialized methods, and the outcomes are evaluated using four advanced metrics. From the obtained results of experiments and comparisons, the developed algorithm demonstrated the ability to process various color and grayscale images, performed the best among the comparative methods, and scored the best in all four quality evaluation metrics. The findings of this study are significant because the proposed algorithm has low-complexity and can adjust the contrast of different images expeditiously, which enables it to be used with different imaging modalities especially those with limited hardware resources or produce high-resolution images.