The woman told Stanford police that at about 6:40 p.m. Monday, a man called out to her as she walked near Manzanita Field, which is close to the intersection of Serra Street and Campus Drive.
The man said something like, "Hey girl," before he grabbed her from behind and placed his hand over his mouth, police said.
The victim tried to bite her attacker's hand, causing him to flee, police said.
The attacker is described as a white man in his 40s who was wearing a dark hooded sweat jacket. He had a mustache or goatee, brown hair, and a thin build.
Police are encouraging students to walk in pairs, use suggested travel routes, note the location of emergency blue tower phones, and carry a cell phone.
Anyone with information is asked to contact Stanford police at (650) 329-2413.