Map from Google - Genoa

The climate of Genoa, capital of Liguria, is Mediterranean, with mild and rainy winters, and hot and sunny summers. The city is located in northern Italy, but on the coast, and it's clearly separated from the Po Valley by the Apennines, so along with the rest of the Ligurian Riviera it has a much milder climate.
The wind is quite frequent, since in periods of bad weather a depression often forms right on the Gulf of Genoa, which draws to the city a moderate or strong northeast wind, able to lower the temperature.
Here are the average temperatures.
Average temperatures - Genoa
GenoaJanFebMarAprMayJunJulAugSepOctNovDec
GenoaJFMAMJJASOND
Min (°C)6681114182121181497
Max (°C)121215172124272824201513

The rains in Genoa are quite abundant, given that they exceed 1,000 millimetres per year; in particular autumn is very rainy, when the sea is still warm, and the first disturbances are capable of causing heavy rains, which in turn can lead to flooding of the streams coming down from the Apennines and passing through the city, especially in late September and in October. October is the wettest month, with as many as 170 mm on average. Summer is the driest season, but only in July, when the disturbances are rarer, precipitation falls below 30 mm.
Here is the average precipitation.
Average precipitation - Genoa
GenoaJanFebMarAprMayJunJulAugSepOctNovDecYear
GenoaJFMAMJJASONDY
Prec. (mm)10075809070602570135170110951080
Days86787535687777

Winter, from December to February, is mild; in particular, periods of good weather are pleasant, when the sun shines, while the Po Valley is shrouded in fog. Instead, in periods of bad weather, with the wind from the north-east, the cold air of the Po Valley manages to climb over the Apennines and gets to the city, so that you can have cold and rainy days. In colder periods, still for the same reason, it may even snow, although the snow tends to melt quickly, because the seaside location makes frosts rare, and in any case light.

Spring, from March to May, is mild and gradually becomes more sunny, but it is also quite rainy. March and the first half of April are unstable periods, in which the first mild and sunny days alternate with colder and rainy days. In April and May, while in the rest of Italy the first very mild days occur, with highs above 20 degrees, sometimes on the Ligurian coast a layer of clouds can form, able to keep the temperature cool, around 15 °C even during the day.

Summer, from June to August, is hot and sunny. Generally the heat is not excessive, thanks to the influence of the sea and the breeze, but you can not rule out some particularly sultry periods. Some disturbances may also pass in the summer, especially in June and in late August, while on sunny days some thunderstorms may reach the coast from the interior.

Autumn, from September to November, is mild and humid, with sunny days, but also periods of bad weather, in which as we have said it can rain a lot.

The amount of sunshine in Genoa is good in summer, when clear skies prevail, while in the rest of the year, sunny periods alternate with periods in which the sky is cloudy.

Genoa

The sea in Genoa and in nearby locations, such as Rapallo and Chiavari, becomes warm enough for swimming in July and especially in August, when it reaches 25 °C, while in June the Ligurian Sea is still cool.
Here are the average sea temperatures.
Sea temperature - Genoa
GenoaJanFebMarAprMayJunJulAugSepOctNovDec
GenoaJFMAMJJASOND
Sea (°C)131313141720232522191614

In the hills north of Genoa the climate gets much colder, already at altitudes of a few hundred metres, as you can see from the average temperatures of the Giovi Pass, 475 metres above sea level.
Average temperatures - Passo Giovi
Passo GioviJanFebMarAprMayJunJulAugSepOctNovDec
Passo GioviJFMAMJJASOND
Min (°C)-2126912141411830
Max (°C)571014172124242016107

When to go

The best times to visit Genoa are spring and early summer, in particular from mid-April to mid-June. Also September is a good month, especially in the first half, because then the risk of heavy rainfalls increases.
In the height of summer, in July and August it can be hot, although less frequently than in other parts of Italy.
For a beach holiday on the Ligurian Riviera, the best months are just July and August.