Shanghai weather is characterized by generally mild winters and hot, humid summers.  The best time to go is late September to November timeframe, when days are generally quite pleasant.  The winter months, December through February, are typically chilly but not snowy.  Late spring is the rainy season, usually extending from mid-April through end of May.  The rainy season can be 2-3 straight weeks of endless drizzle and gray, dreary skies.  July and August are hot and humid, so be sure to stay well hydrated (bottled water is available everywhere and very cheap).  In August, an occasional typhoon will make its way toward Shanghai, but they normally hit well south of the city so Shanghai only sees a heavy rainstorm from it.

There are four national holiday periods in China which you will want to take into account as you plan your travel. Spring Festival is Chinese New Year (travel one week before and one to two weeks after is very busy). QingMing is the first few days of April.  May 1-3 is the Labor Day holiday, and finally, Oct. 1-7 is National Week, commemorating the founding of the PRC.  During these periods hundreds of millions of Chinese travel inside the country.  Trains and buses are usually sold out well in advance.  Flights are usually ok, but discounts are fewer.  Upper-end hotels are  quite empty with bargains to be found, as all business-to-business activity comes to a halt.  No expense-account travel occurs.  Lower cost Chinese hotels, however, may be sold out.  At popular tourist destinations, such as Hangzhou south of Shanghai, expect huge crowds of Chinese enjoying their holidays.