take place and large number of EV$^{\newmoon +  }$ gets generated which results in opaque device. In addition, the perchlorate and EV$^{\newmoon +  }$ ions move towards positive and negative electrodes respectively. As a result, complete opaque nature of device is obtained with arrangement of ions in the device as shown in the case of V = -3.5V bias case in Fig. 1(c).

Alternatively, it may also be possible that bias induced color change is associated with the (electric) field induced structural change\[27\] of the molecule which may lead to band gap variation and hence change in optical properties\[28\]. To discount this effect control experiment was done by sandwiching viologen between two quartz substrates without the ITO electrode. Schematic for this experiment has been shown in Fig S2 in the SI. The present biasing condition does not provide electrons to the molecule (for possible reduction) but do provide field for any field-related structural change. No color change was observed upto a bias voltage of 50V which suggests that the observed color switching is not related to field induced structural change and more likely reason being the transmission change due to redox process.

The blue color visible as a result of 