A new kind of gel electrolyte containing only organic solvents and an iodide salt-namely 3-methoxypropionitrile(MPN),aniline and AlI 3 -has been prepared.Gel formation results from the Lewis acid-base interaction between the Lewis acid ionic conductor AlI 3 and the Lewis base organic solvent aniline and no additional gelling agent is required.The AlI 3-aniline complex acts both as an ionic conductor and as a gelling agent.The differences between the peaks characteristic of the-NH 2 group and aromatic ring in the FTIR spectra of free aniline and the AlI 3-aniline hybrid confirm the formation of the AlI 3-aniline complex.The photovoltaic performance and long-term stability of dye-sensitized solar cells can be greatly enhanced by the addition of aniline to the AlI 3-MPN liquid electrolyte.