Yes, it's possible, if your gel is robust enough to stand being immersed in a solution.
Let's say that you made your hydrogel using a phosphate buffer and you'd like to replace the dispersion medium with a 50/50 water/ethanol mix.
Prepare the hydrogel as you normally would and place it in the buffer. Allow it to be immersed in the buffer for 1-2 hours. After the first time interval, pipette off the solution and replace it with a 90/10 mix of dispersion medium/final medium. Allow to sit 1-2 hours. Then pipette off the liquid and replace it with an 80/20 mix of the dispersion medium/final medium. Allow to sit 1-2 hours, and repeat, each time increasing the concentration of the final medium in your solvent mix. Eventually you will get to 100% final medium (in this case, the ethanol/water mixture). The difference between your dispersion medium and your ending solution will determine how gently you need to transition (i.e. more steps). I chose 10 steps here but the exact number and duration of each step depends on your system. Note that there is a reason you were using your dispersion medium as the dispersion medium, and if you replace it with something else, your hydrogel may be more likely to fall apart. But if you are transitioning from aqueous to organic solvent for critical point drying or preparation for paraffin embedding & sectioning, etc., this is still an essential process.