I went on an Alaska cruise on Royal Caribbean a couple years ago and have some thoughts. One thing we found out was that oftentimes you could just purchase an excursion when you went ashore. Most of the ports had a place set up on the dock where the local excursion companies could have a booth and would sell their excursions. The prices they charged were far cheaper than what the cruiseline was charging. For our cruise we only purchased two excursions. The first was to ride the train up to the mountain in Skagway. The second was a helicopter ride to see a glacier and to have a nice lunch at a cabin. I'm blanking on which port that was at. Like I said before, both excursions were purchased through the cruiseline. However, when wer arrived at the port for the helicopter ride the weather was foul and the excursion was cancelled. So we ended up just doing the train ride at Skagway.
Now more to the point. After having had that experience and from talking to others who were on the cruise, here's what I'd recommend. If you see an excursion that you're just dying to do, and if money isn't a huge factor, then by all means book it through the cruise line to ensure that you get a spot. But if money is a factor, or if you aren't incredibly picky about the excursion you do, wait until you get to port. Try to get off in one of the first groups, make your way to either the building they have with booths for local excursion companies or the area where the companies are selling them (all ports had groups selling excursions from either a building or tables set up along the pier), and pick the excursion you want. The risk of doing that is they may have aleady sold out their excursion. But the benefit is to save money and have more choices.
That's my 2 cents. I would also highly recommend checking out
www.cruisecritic.com . They have a forum strictly on information for ports of call, which includes loads of information on excursions. One thing that some people do is contact an excursion company before going on the cruise. Going this route avoids the mark-up the cruise lines do. And since there are recommendations from cruisecritic members who have used the excursion company you know you're going to have a good experience.
Hope that's helpful.