San Remo, where it's located

The climate of Sanremo, a city in western Liguria, is Mediterranean, with mild, relatively rainy winters and warm, sunny summers. The city is located on the Western Ligurian Coast ("Riviera di Ponente"), an area that has a particularly mild climate: the average temperature of January, as high as 10 °C (50 °F), is found again only in Southern Italy, while in summer, hot days are rare. It is no surprise that the city is famous for the cultivation of flowers, in addition, there are plenty of palm trees and subtropical species.
On the other hand, the wind blows quite frequently.
In the neighboring towns such as Ventimiglia, Bordighera, Arma di Taggia, Imperia, Diano Marina, Alassio, and Albenga, the climate is similar.
Here are the average temperatures.
Sanremo - Average temperatures
Min (°C)77911151821211814108
Max (°C)131315172124272724211614
Min (°F)454548525964707064575046
Max (°F)555559637075818175706157

Rainfall in the Riviera di Ponente amounts to about 700 millimeters (27.5 inches) per year, and follows the Mediterranean pattern, in fact, it is more abundant in autumn and winter, and hits a minimum in summer, when it rains very rarely.
Here is the average rainfall in the nearby city of Imperia.
Imperia - Average precipitation

Winter, from December to February, is mild. In particular, periods of high pressure are pleasant, when the sun shines, and the temperature can reach or exceed 15 °C (59 °F), while the Po valley is shrouded in mist and maybe in frost. In periods of bad weather, it can be a bit cold, but snow is very rare: for example, it snowed in February 1986 and in February 2010. Frosts are also very rare and almost always light: usually, the temperature does not drop below -2/-3 °C (27/28 °F) even during the most intense cold waves, and it may very well remain above freezing (0 °C or 32 °F) for a whole winter.

Spring, from March to May, is mild and increasingly sunnier, although there are also some rainy days.

Summer, from June to August, is warm and sunny. Generally, the heat is not excessive, thanks to the influence of the sea: it is even rare for the temperature to reach 32/33 °C (90/91 °F), however, some sultry periods or some hot days can not be excluded. Some weather fronts may pass over the city even in summer, especially in June and in late August, while on sunny days, some heat thunderstorms can reach the coast from the interior, but normally, the sun shines.

Autumn, from September to November, is mild and humid, with sunny days, but also periods of bad weather.

San Remo

The amount of sunshine in Sanremo is very good in summer, when clear skies prevail, while in the rest of the yar, sunny periods, which can occur in this season as well, alternate with cloudy periods. In the nearby city of Imperia, there are 2,570 hours of sunshine annually, and the average ranges from 4.5 hours of sunshine per day in January to 10.5 hours in July. Here are the average sunshine hours per day.
Imperia - Sunshine

The sea in Sanremo and in the nearby towns is warm enough for swimming in July and even more so in August, when it reaches 24 °C (75 °F), while in June, the Ligurian Sea is still cool. Here are the average sea temperatures.
Sanremo - Sea temperature
Temp (°C)131313141720232422191714
Temp (°F)555555576368737572666357

Best Time

The best times to visit Sanremo are spring and early summer, in particular, from mid-April to mid-June. September, too, is a good month, especially in the first half, while later, Atlantic depressions become more frequent.
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 Western Ligurian Riviera, the best months are exactly July and August.