NOVELTY - The method comprises supplying a reverse electrodialysis stack comprising membranes with two feed streams, applying a preventive periodic osmotic shock to fouling layers of the membranes during power production of the reversed electrodialysis process and during a relaxation period without power production, washing out foulants by reversal of inlet and outlet, applying electrical pulses to the stack, producing hypochlorite and/or acid at electrodes, and periodically heating the stack. The fouling layers comprise bio-films. The osmotic shock is applied by periodic reversal of the feed streams.    USE - The method is useful for preventing fouling in a reversed electro dialysis process for the generation of energy by mixing river water and sea water.    ADVANTAGE - The method is capable of economically preventing the fouling in the stack in the electrodialysis process thus improving the efficiency and overall performance of the reverse electrodialysis operation and increasing the hydrodynamic and electrical resistance of the stack.    DETAILED DESCRIPTION - The method comprises supplying a reverse electrodialysis stack comprising membranes with two feed streams, applying a preventive periodic osmotic shock to fouling layers of the membranes during power production of the reversed electrodialysis process and during a relaxation period without power production, washing out foulants by reversal of inlet and outlet, applying electrical pulses to the stack, producing hypochlorite and/or acid at electrodes, and periodically heating the stack. The fouling layers comprise bio-films. The osmotic shock is applied by periodic reversal of the feed streams by a switching unit, and is applied with a frequency of 2.5x 10-4 to 3x 10-4 Hz and a pulse width of 1-10 seconds. A ratio of ion concentrations between the two feed streams is 100 during the periodic osmotic shock. An INDEPENDENT CLAIM is included for a device for performing a reverse electrodialysis process.    DESCRIPTION OF DRAWING(S) - The diagram shows a schematic view of a device for performing a reverse electrodialysis process.    Cation exchange membranes (4)    Anion exchange membranes (6)    Anode (10)    Cathode (12)    Dialytic cell. (30)