A simple sequential one-pot protocol has been developed to prepare oxadiazolyl and triazolopyridyl-BODIPY derivatives 4–6 by employing iodine (III)-promoted oxidative cyclization of BODIPY hydrazide-hydrazones which are readily accessible from the reaction of formyl BODIPYs with arylhydrazides. Photophysical studies of the prepared compounds 4–6 showed a significant red shift in absorption and emission maxima when compared to that of the parent BODIPY. Presence of triazolopyridyl substituent in 6a has affected its binding ability with metal ions and has rendered unique photophysical response by 6a selectively in presence of Hg2+ ions. Compound 6a showed high affinity towards Hg2+ (Ka = 1.8 × 104 M−1) with 2.1 μM limit of detection. The binding stoichiometry between 6a and Hg2+ was determined to be 2:1 by Job's plot analysis. Under acidic conditions, compounds 4c, 5c, 6a and 6b bearing dimethylamino- and triazolopyridyl moieties at α/β-positions of BODIPY unit exhibit blue shifted absorption (10–15 nm) and emission spectra (7–34 nm). Photophysical response of the compounds 4c, 5c, 6a and 6b on changing pH was validated by DFT calculations.