San Francisco's climate is characteristic of California’s Mediterranean climate with mild, wet winters and dry summers. Since it is surrounded on three sides by water, San Francisco's climate is strongly influenced by the cool currents of the Pacific Ocean which tends to moderate temperature swings and produce a remarkably mild climate with little seasonal temperature variation. The dry period of May to October is mild to warm, with average high temperatures of 64-70°F (17-21°C) and lows of 51-56°F (10-13°C). The rainy period of November to April is cool with high temperatures of 56-64°F (13-17°C) and lows of 46-51°F (7-10°C). On average, temperatures exceed 75°F (24°C) 28 days a year.
The combination of cold ocean water and the high heat of the California mainland create the city's characteristic fog that can cover the western half of the city all day during the spring and early summer. In fact, a quotation incorrectly attributed to Mark Twain is "The coldest winter I ever spent was a summer in San Francisco." The fog is less pronounced in eastern neighborhoods, in the late summer, and during the fall, which are the warmest months of the year. Due to its sharp topography and maritime influences, San Francisco exhibits a multitude of distinct microclimates. The high hills in the geographic center of the city are responsible for a 20 percent variance in annual rainfall between different parts of the city. They also protect neighborhoods directly to their east from the foggy and cool conditions experienced in the Sunset District; for those who live on the eastern side of the city, San Francisco is sunnier, with an average of 260 clear days, and only 105 cloudy days per year.