Map from Google - French_Riviera

The climate of French Riviera, the coastal French area that goes from Marseille to Menton (near the border with Italy), is Mediterranean, with relatively mild and rainy winters, and warm, sunny summers. Atlantic frontal systems pass quite often throughout the year, but especially from October to April. In winter, though rarely, there may be waves of cold, with snow on the coasts and frosts in inland areas. Typically the summer temperatures are acceptable, although sometimes there may be hot periods, with highs about 95 °F, but fortunately sea breezes blow along the coast. On other occasions, we can not exclude the passage of some Atlantic depressions even in summer.
The western part is colder than the east, especially in winter, because it is subject to a cold and impetuous wind, the Mistral, which blows a hundred days a year, and is channeled through the Rhone Valley. So winter in Marseille is quite cold: the average temperature in January is 43.5 °F, and from November to March cold and windy days are possible, which can be followed by frosts. Precipitation in this westernmost part is not abundant: in Marseille about 23.5 inches of rain per year fall, with a maximum in autumn and a minimum in summer.
Here are the average temperatures of Marseille.
Average temperatures - Marseille
MarseilleJanFebMarAprMayJunJulAugSepOctNovDec
MarseilleJFMAMJJASOND
Min (°F)373941465459646359524539
Max (°F)505257637077828175665752

In cities located at a certain distance from the coast, the climate is slightly continental, as you can see from the temperature of Aix-en Provence, about 12 miles north-east of Marseilles, where the average in January drops to 42 °F.
Average temperatures - Aix-en-Provence
Aix-en-ProvenceJanFebMarAprMayJunJulAugSepOctNovDec
Aix-en-ProvenceJFMAMJJASOND
Min (°F)323237414855615954483736
Max (°F)545459647279888679705754

Proceeding eastwards from Marseille, and away from the mouth of the Rhone River, the climate becomes milder, while the rains become more abundant in autumn and winter; in summer however it continues to rain a little.
In Toulon, in the southernmost part of the coast, nearly 28 in of rain per year fall, with a peak in October and November of 3.5 inches per month, and a minimum in July of just 0.4 in. Here are the average temperatures.
Average temperatures - Toulon
ToulonJanFebMarAprMayJunJulAugSepOctNovDec
ToulonJFMAMJJASOND
Min (°F)414145485461646461554843
Max (°F)545559637077828277706155

Continuing east, in cities like Saint-Tropez, Cannes, Nice, the temperatures are similar. Here are the average temperatures in Nice.
Average temperatures - Nice
NiceJanFebMarAprMayJunJulAugSepOctNovDec
NiceJFMAMJJASOND
Min (°F)414346505763686863554843
Max (°F)555559636875818175706157

The rains increase a bit, exceeding 27 inches per year, and reaching 31.5 inches in Monte Carlo. From late September to December, in some years the rains are plentiful.
Here are the average precipitation in Nice.
Average precipitation - Nice
NiceJanFebMarAprMayJunJulAugSepOctNovDecYear
NiceJFMAMJJASONDY
Prec. (in)2.81.81.62.81.81.40.40.82.85.34.13.729.1
Days65575422577661

The sunshine duration on the French Riviera is good in the summer, when the weather is usually nice, and decent in spring, especially in April and May, and again in September. In the rest of the year, ie in autumn and winter, there's no shortage of sunny days, but they alternate with cloudy and rainy days.

Nice from above

On the French Riviera, the sea is never very warm, because it is cooled for several months every year by the Mistral (which obviously blows in the western part, but due to sea currents, cold waters expand in a larger area). So in Marseille the sea temperature reaches a maximum of 72 °F in August.
Here are the average sea temperatures in Marseille.
Sea temperature - Marseille
MarseilleJanFebMarAprMayJunJulAugSepOctNovDec
MarseilleJFMAMJJASOND
Sea (°F)555555576164707270646157

In the eastern part of the coast, the sea becomes a bit warmer in the summer months (about one degree Celsius), as you can see from the temperature of the sea in Cannes.
Sea temperature - Cannes
CannesJanFebMarAprMayJunJulAugSepOctNovDec
CannesJFMAMJJASOND
Sea (°F)555555576166727370666157

When to go

The best time for beach life on the French Riviera is the summer, from mid-June to August.

If you want to visit cities, you can choose the months of May, June and the first half of September, to avoid the warmest months, bearing in mind that sometimes it can rain during the passage of depressions or in the form of afternoon thunderstorm.