Officers went to the 8300 block of Arroyo Circle at about 7 p.m. after dispatchers received an anonymous call reporting a male stabbing victim in that area, according to police.
Arriving officers found the victim standing in front of a retail store suffering from a single stab wound in the torso, police said.
He was taken to a hospital and is expected to survive.
The victim, who identified himself as a gang member from another city, told investigators he had been attacked by two people.
Police believe the assailants were from a rival gang.
Anyone with information about the stabbing is asked to contact Gilroy police Cpl. Dutton at (408) 846-0350.