Modern development of flexible electronics has made use of bioelectronic materials as artificial tissue . As hydrogels are more similar to nerve tissue, functional hydrogels have become a promising candidate for bioelectronics. Meanwhile, interfacing functional hydrogels and living tissues is at the forefront of bioelectronics. The peripheral nerve injury often leads to paralysis, chronic pain, neurologic disorders, and even disability, because it has affected the bioelectrical signal transmission between the brain and the rest of body. Here, a kind of light-stimuli-responsive and stretchable conducting polymer hydrogel (CPH) is developed to explore artificial nerve. The conductivity of CPH can be enhanced when illuminated by near-infrared light, which can promote the conduction of the bioelectrical signal. When CPH is mechanically elongated, it still has high durability of conductivity and, thus, can accommodate unexpected strain of nerve tissues in motion. Thereby, CPH can better serve as an implant of the serious peripheral nerve injury , especially in the case that the length of the missing nerve exceeds 10 mm.