<p>An optical sensor for colorimetric detection of Cr(VI) has been synthesized by immobilizing 1,5-diphenylcarbazide (DPC) into alginate/pectin films. The addition of cationic surfactant (CTAB) was used to increase the effectiveness of DPC immobilization by forming hydrophobic-ion pairs. At optimum condition, the films has good selectivity for Cr(VI) compare to other interference metals. The formation of violet color in the films showed its potential application for visual colorimetric detection of Cr(VI). The developed films in this study was found to be simple, rapid and sensitive sensor for direct determination of Cr(VI) with detection limit as low as 0.233 mg L–1 and time response was 8 minutes.</p>