In this study, we synthesized the new kinds of semiconducting polymeric gels having negative (n-type) and positive (p-type) counter ions as charge carriers. The polyacrylamide gel was doped with pyranine (8-hydroxypyrene-1,3,6-trisulfonic acid, trisodium salt), having SO(3)(-) ions as side groups and Na(+) as counter ions, so-called p-type semiconducting gel. The doping process was performed during the polymerization where the pyranine binds to the polymer strands over OH group chemically via radical addition. In a similar way, N-isopropylacrylamide (NIPA) gel was doped with methacrylamidopropyltrimethyl ammonium chloride (MAPTAC), having Cl(-) as counter ions, so-called n-type semiconducting gel. Here MAPTAC was embedded by copolymerization within the polymer network (NIPA). These semiconducting gels can show different electrical properties by changing the concentration of the doping agents, swelling ratio etc. We have shown that the pn junction, formed by combining p-type and n-type gels together in close contact, rectifies the current similar to the conventional Si and Ge diodes.