Not only Ghokarna .Best time to visit any place is winter's December to Feb is the best time to visit Ghokarna so that you can enjoy the view + the climate.
Winter is the best time as it becomes really hot in summer. It’s better to stay at kudle and trek to other 3 beaches. So trekking in summer is something I won’t recommend. For detailed itinerary u can read my blog in Tripoto
It's better to go in November to avoid rain in monsoon .1st day u can go to mirjan fort ,yana caves 2nd day u can go to beach treaking in gokarna 3rd day u can go to mahakaleshwar temple and karwar black sand beach