Why is the weather in San Francisco so different from that in San Jose? San Francisco has around 5 months a year of intermittent rain. San Jose, just 50 miles south and nestled between mountains instead of between waters, has perhaps only 1 month of rain. San Francisco also has notably colder winters and summers than San Jose, to a fairly shocking degree.
Geographical differences are three, primarily. First of all, San Francisco is further north, and closer to the Pacific Northwest, but only by 50 miles, or 80 kilometers. Second, San Francisco is surrounded by water, with the San Francisco Bay to the east and the Pacific Ocean to the West, while San Jose is isolated from the Pacific by the Santa Cruz mountains. Third, San Francisco has a far higher population density, with more smog and greenhouse gases as a result, which may or may not be a significant contributor to rain (nucleation sites?).
Why do these two so proximate cities have such different climates?
San Francisco is more exposed the maritime westerly weather, whereas San Jose is in a rain shadow region with a mountain range between it and the Pacific Ocean.

San Jose, California, and adjacent cities are usually drier than the rest of the San Francisco Bay Area because of the rain shadow cast by the highest part of the Santa Cruz Mountains.

The exposure of San Francisco to westerly maritime weather and being surrounded by water on three sides are significant reasons why it has a milder climate. It's climate is largely influenced by the cold California Current.

Due to the Bay Area's diverse topography, the result of the clashing tectonic plates, the region is home to numerous microclimates that lead to pronounced differences in climate and temperature over short distances.

San Jose however is slightly inland and is surround by mountains of three sides, has less rain and an average of 301 sunshine days each year.