Im a solo female from Ireland and I spent a few days in San Francisco in June 2017.
I stayed in a motel, Travel Lodge at Fishermans Wharf and walked around that area and spent the day over on Alcatraz Island. I dont drive and used super shuttle from and to the airport.
Honestly I didnt feel any less safe than I do in any major city. I guess I am just aware of personal safety and I did research about which areas to avoid.
I dont walk around after dark, I stay in tourist areas. I dont use my phone when walking around, I wear a money belt under my clothes and Im very observant of my surroundings.
Also in my home city we have a homeless problem too, so seeing pan handlers, rough sleepers etc is not shocking to me. In my home city I have seen drug taking on public transport, I have been on buses where Police have been called due to passengers fighting. I live in Dublin, Ireland land of shamrocks, leprechauns , and cead mile failte / hundred thousand welcomes, where only today, The
Disney Store has caused controversy as it wants to put a metal gate at the shop entrance to stop rough sleepers at night in their door way. Their staff get abuse in the mornings when opening the shop and have to clean up human waste and drug paraphernalia
My point is, anything you read about San Francisco can be about any major city in any country.
Be aware of personal safety. do research on the area , then go and have a good time