We have identified a strategy to communicate a chemical signal between two independent molecular components. One of them is a photoactive merocyanine that switches to a spiropyran, releasing a proton, when stimulated with visible light. The other is a 4,4‘-pyridylpyridinium monocation that captures the released proton, producing an electroactive 4,4‘-bipyridinium dication. Under the irradiation conditions employed, the photoinduced transformation requires ca. 15 min to reach a photostationary state. In the dark, the ensemble of communicating molecules reequilibrates to the original state in ca. 5 days. These processes can be monitored following the photoinduced enhancement and thermal decay, respectively, of the current for the monolectronic reduction of the 4,4‘-bipyridinium dication. The pronounced difference in time scale for the current enhancement and decay steps can be exploited to implement a memory element with a bit retention time of 11 h. A bit of information can be written optically in the chemical system and it can be read electrically and nondestructively. The memory can be reset, extending its permanence in the dark beyond the bit retention time. A binary logic analysis of the signal transduction operated by the communicating molecules reveals the characteristic behavior of sequential logic operators, which are the basic components of digital memories.