Ansbach is pleasant in any season — it is a small town and doesn't get crowded. The main draw for timing a visit is the Rokoko-Festspiele in July, when the Residenz and Hofgarten host baroque music concerts with performers in period costume. Tickets sell out early, so book ahead if this is the goal.
The Hofgarten is at its best in June and July when the formal parterres are planted and the lime trees are in leaf. Autumn in the surrounding Franconian countryside is beautiful, with vine and forest colours, and the town is quiet and easy to navigate. Winters are cold but the old town's baroque architecture looks fine in snow.
Every four years Ansbach holds a Kaspar Hauser Festival — a weekend of theatrical events, historical re-enactments, and exhibitions around the mystery figure. Check local listings for the year of the next festival.