When your character uses a skill, he isn't guaranteed success. In order to determine success, whenever you attempt to use a skill, you must make a skill check.
Each skill rank grants a +1 bonus on checks made using that skill. When you make a skill check, you roll 1d20 and then add your ranks and the appropriate ability score modifier to the result of this check. If the skill you're using is a class skill (and you have invested ranks into that skill), you gain a +3 bonus on the check. If you are not trained in the skill (and if the skill may be used untrained), you may still attempt the skill, but you use only the bonus (or penalty) provided by the associated ability score modifier to modify the check. Skills can be further modified by a wide variety of sources—by your race, by a class ability, by equipment, by spell effects or magic items, and so on. See Table: Skill Check Bonuses for a summary of skill check bonuses.
Table: Skill Check Bonuses
||Skill Check is Equal To*
||1d20 + ability modifier + racial modifier
||1d20 + skill ranks + ability modifier + racial modifier
|Trained Class Skill
||1d20 + skill ranks + ability modifier + racial modifier + 3
|* Armor check penalty applies to all Strength- and Dexterity-based skill checks.|
If the result of your skill check is equal to or greater than the difficulty class (or DC) of the task you are attempting to accomplish, you succeed. If it is less than the DC, you fail. Some tasks have varying levels of success and failure depending on how much your check is above or below the required DC. Some skill checks are opposed by the target's skill check. When making an opposed skill check, the attempt is successful if your check result exceeds the result of the target.