Here's a paladin code I stole from someone else on the boards.
Actions that may result in a paladin’s punishment:
<ol>
<li>If the paladin commits rape. </li>
<li>If the paladin purposely violates a lawful order given by proper authority. (rulers, etc.) If the order was unlawful/unjust, or despite being lawful, the disregarding of said orders was appropriate because of information that the paladin has, then no punishment is warranted.</li>
<li>If the paladin purposely, and with malicious intent, murders someone who:
<ol> <li> Isn't attacking him, or anyone, with deadly force, or credibly threatening to do so. (E.g., drunken old men in the tavern do not count.)</li>
<li> The paladin does not have warrant to attack. (No foreknowledge of said villain, dangerous criminal, rebel, or cultist, etc.) </li>
<li> A creature, or class of beings that is not generally assumed to be EVIL: e.g., demons, devils, great and terrible monsters (Evil/Chromatic Dragons, Bullettes, Purple Worms, the Tarrasque, etc.), non-intelligent undead, and most intelligent undead. Non-intelligent creatures may safely be slain. Creatures with intelligence of 1 or 2 (for reasons other than ability damage) are animals, and killing them doesn’t constitute murder. However, the paladin respects all life, and only kills such creatures if the pose a “real” threat to the paladin or others, or if needed for food or materials. (Slaughter of animals may be punished to a lesser extent.)</li></ol></li>
<li> If the paladin is has purposely, maliciously been deceitful for purposes beyond serving an "ultimate good." That is:
<ol> <li> Paladins should generally act in a loving manner towards people (Loving being defined as what is ultimately the best for them, expressing the most respect for them as people, wanting the best in life for them, and treating them how you would desire to be treated).</li>
<li>"Always" being totally honest with people can sometimes get people killed, cause the loss of jobs/reputation, or simply really hurt someone’s feelings needlessly. Thus, the paladin should strive to be honest when possible, but he may, and in certain cases should, be dishonest if doing otherwise would cause loss of life, suffering, or unwarranted punishments to befall any creature. He may also exercise tact. He may not be dishonest to serve any greedy or malicious purpose.</li>
</ol></li>
<li>If the paladin commits theft of whatever amount or value. Stealing an apple is, in the larger context, dishonorable in the same way that stealing a masterwork greatsword, or whatever. The punishment won't be the same, of course, but the level of disapproval is the same. Stealing may be justifiable only in the name of good (raiding villains’ armories, stealing medicine or food for needy people - only if the paladin cannot otherwise reasonably obtain it).</li>
<li>If the paladin becomes involved in a lifestyle of sexual immorality. For example, if the paladin gets wild one night during celebrations, and enjoys a relationship with a whore, and afterwards, he feels bad about it, feels guilty, enters into prayer, and so on--by himself--no punishment is necessary. Should he do it again, and again, by degree, frequency, and so on, the paladin may receive a vision, have some kind of dream, onwards up to the loss of powers.</li>
<li>If the paladin should act in such a way as to be dishonorable. If the paladin was to shaft a friend, or desert a comrade in need. Or heartlessly ignore the pleadings of innocent people suffering under attack or oppression. For example, should the paladin pretend to offer to parley, only to go ahead and stab the other party, or if the paladin formally gives his word of honor that he will do, or not do, whatever, and then violates it. As an example, a group of Orcs after combat specifically offers to peacefully surrender, if the paladin promises not to kill them, and to treat them well. If the paladin agrees, and then instead tortures them, and executes them, major punishment would come down!
However, if the paladin then escorts the Orc-prisoners and someone of HIGHER AUTHORITY takes control of them, and later executes them, or does any kind of atrocity to them, the paladin in question may be angry, or sad, and may try to save them or whatever, but the paladin isn't held to be guilty at all. He did what he promised. That is keeping his word of honor. Any vicious atrocities committed would be accounted to the person who did them. The paladin isn't responsible for what other people choose to do. He would, let’s say, while escorting the Orc-prisoners, feed them, water them, and protect them, even with his life, from all harm. Until the Orcs be turned over to higher, proper, authority. Proper authority, of course, is empowered to then render an official and binding judgment.</li>
<li>If the paladin should offer sacrifices and offerings to false gods, evil gods, etc. The paladin's patron god/gods expect faithfulness from such a worshipper who has been so blessed. The paladin may freely give offerings or pray to good or neutral gods who are not his patron deity.</li>
<li>If the paladin should begin a process of attitudes, or adopting philosophies, that are anathema or heretical to the "True Faith." This, while not damnable in one instance, over time represents a form of "spiritual adultery" that will, eventually, bring wrath and judgment down upon the compromising paladin.</li>
<li>If the paladin should take direct actions, or refuse noble duties and requests, out of a sense of greed. Of constantly wanting more and more wealth, of being willing to sacrifice a friend, or the mission, so as the paladin may gain wealth: gold, gems, magic, whatever. Even the prospect of acquiring a Holy Avenger while honorable in itself, acquiring it at the expense of your comrades, or your honor, is thus guilty of getting a "right" thing by the wrong methods, or attitudes.</li>
<li>If the paladin should use poison, unless this is absolutely necessary. A true paladin would consider the undue use of poison cowardly, at best. The use of starvation tactics (e.g. laying siege, cutting off supplies of food/water from troops) is only slightly more tolerable, and the paladin will try to allow enough food and water to ensure that no deaths result, if circumstances permit.</li>
<li>If the paladin ignores requests for help, except in the event that more pressing needs present themselves. Not trying to help a kid being attacked by thugs because he needs to go shopping is bad. If, on the other hand, the paladin is racing against time to save the world and passes by a city that is under attack by a huge Orc army, he is not obligated to help since:
<ol><li> it’s debatable whether or not the one paladin would have made much of a difference, and </li>
<li> if the world blows up, it doesn’t matter whether the Orcs took over the city or not.</li></ol></ol>
The paladin may commit minor offenses in extreme circumstances, and to prevent more major ones from occurring. It is generally reasonable, and justifiable, both in a moral sense, and logically, that the acknowledged sacrifice of "some" innocent lives, while prosecuting the struggle against the forces of darkness is while tragic, and regrettable, is nonetheless often unavoidable, and thus generally acceptable. What constitutes a reasonable violation is up to the paladin’s god, and thus the DM. The player is entitled to defend the actions of his paladin, but if the DM afterwards decides that the paladin was still guilty beyond a reasonable doubt, then the matter is closed. Note, however, that it is important to distinguish between "Evil" behaviors/actions, and "foolish/dumb/immature/wrong" behaviors, as they are not the same. The paladin may do many of the latter, and shouldn't be punished, beyond a possible censure or slap on the wrist for repeated behavior. The other in-game consequences of such behavior should be more than enough to teach the character his lesson without losing his powers in addition.