The announcement was made at a Project Homeless Connect event at the Bill Graham Civic Auditorium Wednesday.
A homeless person will be able to call in for his or her messages from any phone.
The move by the city and the company would allow someone to be able to fill out a job application, which asks for a call back number.
It will allow clinics to share test results.
Mayor Gavin Newsom and Google said they want to empower people.
"How do you communicate as a homeless individual? " Newsom asked. "How do you expect your life to turn around if you can't even get information or if someone can't even get in touch with you?"
"It just seems exactly like any other voice mail," said Craig Walker, senior project manager of Google. "There's no stigma attached to it that 'hey this is a temporary thing' or 'this is an 800 number.' It's really just a local number owned by the user."
One man who used to be homeless said the right message can raise the spirit.
"Having your family, friends and loved ones being able to say 'here I'm thinking about you, I love you, I want you to know you're mine, and I miss you,' can have a monumental change in one's behavior."
"Providing phone and messaging capabilities and access to vital health care is an extraordinary step forward in the city's commitment to a comprehensive approach to addressing the needs of this vulnerable community," Newsom said.
"We're firm believers in the power of technology to improve the daily lives of individuals and communities as a whole, and we recognize that access to phone and voicemail services is one way that Google can help San Francisco's homeless stay connected with family, friends, social workers, health care providers, and potential employers," Walker said.
Walker said the program was ready to start right away.