Although I've almost always lived in the San Francisco area, for a very short visit I would recommend San Diego. It has a smaller, more manageable airport, and the city feels less crowded to me – easier to get around when you don't have a lot of time to learn the lay of the land. Also, since you're going in June, you can count on better weather in San Diego and San Francisco. Summer in San Francisco tends to be cold and foggy; warm weather commonly comes in the early fall. Regarding the San Francisco rain that someone mentioned above, I wouldn't worry about that – we're in our third or fourth year of drought, and rain in June is pretty unheard of even if we were not in a drought.
If you can add another day or two, I have a different recommendation. I'd suggest flying into San Francisco, spending a day visiting a few of the highlights of the city, and then renting a car to drive down Highway 1. You could decide how far you wanted to go down the coast, and whether you would continue on to LA and fly out of there or return to San Francisco for your continuation flight.
Some favorites... The Monterey Bay Aquarium is probably the best I've ever seen. It's also in an absolutely stunning setting. The next town south, Pacific Grove, has a long stretch of really beautiful rocky beach, which is great place for walking. When I'm in the area, usually stay in Pacific Grove because it's a lovely little town dating from maybe the 20s, much quieter and more pleasant than Monterey, and much less expensive than Carmel. If you go to Pacific Grove, the Fish Wife is a great restaurant. Carmel comes next, with a beautiful white beach, and lots of interesting galleries, shops, and restaurants. Just a little further south is Point Lobos, which combines a variety of stunning seascapes in a very compact area, with offshore colonies of sea lions, harbor seals, and sea otters. The next 75 miles south is the Big Sur coast – Wonderful sea views, several nice parks where you can stop to hike, and June is a good time for wildflowers (assuming we get some rain).