Copy Paste of guidance for newer players in my guild:
You basically want to recruit about 50% mages, 20% archers, 20% infantry, 10% cavalry, with alot of extra level 2 cavalry strictly for gather
Mages have highest attack and ranged - they are easily (in combination with other troops) the best at city offense, city defense, and killing monsters
Archers have slightly less range & damage than mages but are a good secondary damage source - you need more than your mages dealing out damage since enemy lord troops tend to be split up into combat groupings (up to 9 on offense including angels, 10 on defense including angels and golems)
Cavalry are much less useful in attack and defense - they help a bit in city defense but are mostly used for gather or attacking undefended cities (when players begin to quit realm)
Infantry are defensive meat shields - they occupy enemy troops, buying time for, and limiting damage to, your ranged troops (mages & archers)
Special note on cavalry - you want a ton of level 2 in all likelihood - even when you unlock higher level - as they are fast, have high "load" score, are cheap to recruit, making them perfect for big gathering expeditions. Your level 2 gather ponies are outside of the % guidelines above
you will unlock higher tier troops at barracks levels (your barracks level is limited by your castle level) 1,4,7,10,13,16,19,22,25,3
As you're closing in on unlocking the next tier of troops, focus your resources on those upgrades - don't pile up battle power in the form of too many low level troops. Enough to gather, kill monsters, participate in raids once we get aggressive