Caveat the First: I Am Making Broad Generalizations
There are cases where you might want to break these.
Caveat the Second: I Am Not Overly Familiar With Pathfinder
I have read the Core rule book, but none of the supplemental material, including the archetypes (alternate class features in 3.5 lingo), and Paizo did make it a goal to counter, at the very least, my point #2. Within the Core material that I have read, I would argue that they largely failed. I have heard that they have done somewhat better with the supplemental material, but I would not know. Mostly, the answer is really only being given for 3.5, with the understanding that Pathfinder Core changed very little in any significant way.
Caveat the Third: I View Classes as Purely Metagame Concepts
I have little to no problem with multiclassing, even a great deal of multiclassing, because in my games a character does not think of himself as a Paladin 6 or a Barbarian 2/Rogue 1/Cleric 1/Swordsage 2 – he thinks of himself as a knight, or a mercenary, or a mystic, or whatever.
Or, say, a Monk 2/Paladin 6 thinks of herself as a Samurai.
Each class is, as far as I am concerned, a bundle of mechanical features with some suggested ideas for what sort of person would have them. Players at my table know, for instance, that they don’t even have to ask if they want to treat, for instance, Rage as instead “Zen Focus,” so long as the mechanics do not change. Most abilities are reasonably generic and can be understood as a lot of possible things in character.
Multiclass characters can represent a change of heart – someone who used to train one way abandoning it for another – but particularly when you start at levels above 1 and you start with levels in a few classes, it often makes more sense to think of a multiclassed character as someone who pursued one path their whole life – that path is just mechanically represented by different classes.
1. Spellcasters should not multiclass
Spellcasters, as well as manifesters, will always benefit most from getting the highest-level spells (powers) available at a given level. Their spellcasting (manifesting) progressions benefit only from more (effective) levels in their class.
Note that technically in 3.5 jargon, prestige classes do not count as multiclassing, but a separate thing. Prestige classes can be very good for spellcasters, since they frequently have few or no class features aside from their spellcasting, and many prestige classes advance spellcasting on a 1:1 basis. In some cases, this can literally be “something for nothing,” as the prestige class provides class features while not costing a spellcaster anything from their base class.
2. Mundanes should multiclass
Mundane classes (and the weaker half-casters, usually the ones who stop at 4th-level spells) do not have a solid progression like spellcasters do. Furthermore, most of them are extremely front-loaded. For examples:
- Barbarian gives Rage, and potentially Pounce (Lion Spirit Totem, Complete Champion) in one level. Level 2 can get you Improved Trip without prerequisites (Wolf Totem, Unearthed Arcana). Beyond that, the next significant benefit comes at 11th level (Greater Rage).
- Fighter gives a lot of proficiencies and a feat at 1st level, and another feat at 2nd, but nothing at third, and thereafter the rate of ½ feats per level, which is not good.
- Monk gives a couple of feats in addition to improved Improved Unarmed Strike, plus Evasion and Flurry of Blows, in the first two levels. It proceeds to give nothing much for the next 18.
- Ninja (Complete Adventurer) gets Ghost Step at 2nd, and little else until it gains the ability to become Ethereal.
- Ranger can get some combat feats without prerequisites and gets a feat per level until 3rd, but is overall not a great class.
- Rogue, and most Sneak Attack-ing classes, grant 1d6 Sneak Attack damage each odd level. By taking an odd number of levels in multiple Sneak Attack-granting classes, you can gain higher Sneak Attack damage than a single-classed Rogue would get.
And so on. So a Barbarian 2/Fighter 2/Monk 2/Paladin 2 has way more class features than a Barbarian 8, Ranger 8, Fighter 8, or Paladin 8.
Note that Cleric 1 is quite probably the best single-level dip in the game, despite also being a fullcaster that you can focus all 20 levels on. In this sense, Clerics are both martial and magical. Even characters without enough Wisdom to cast Cleric spells can make good use of a Cleric dip.
Psychic Warriors are another exception: if you aren’t absolutely requiring full BAB, Psychic Warrior 2 can get you the same feats that Fighter 2 can, plus a few Powers which can be very useful to an otherwise-mundane warrior.
3. Those in between can go either way or, sometimes, halfway between
You can dip Bard for Bardic Knowledge, Inspire Courage, and fascinate, or you could focus on Bard to get its quality spellcasting. Binders (Tome of Magic) and meldshapers (Magic of Incarnum) can be dipped for a select Vestige or Chakra bind, or focused on to maximize those features.
Factota (Dungeonscape) go even further and are solid at 1 (all skills in class), 3 (Brains over Brawn), 8 (Cunning Surge), or 20 levels. Binders and meldshapers are also reasonably good at being worth however many levels of them you want to take.
4. Tome of Battle is exceptional and unique
Tome of Battle classes multiclass better than any other classes in the system, because they add half their level in other classes to their Initiator Level, and can select higher-level maneuvers based on this improved Initiator Level. That means unlike a Fighter 8/Wizard 1, who gets 1st-level spells, a Fighter 8/Warblade 1 has Initiator Level 5 and gets 3rd-level maneuvers.
Ardents (Complete Psionic) have a somewhat-similar mechanic for determining what level of power they can use, but no built-in bonuses to their Manifester Level from other classes. The Practiced Manifester feat (also Complete Psionic), however, means that an Ardent can take up to 4 levels in other classes while maintaining full Manifester Level and therefore the highest-level powers.