A rule is a provision for what applies in a given area. Rules set absolute standards for our actions. The role of rules is to set limits and prohibit certain behaviors.
A guideline is a document that contains an instruction or recommendation, for example, a policy to be achieved. Guidelines mainly concern issues related to pure enforcement. Guidelines can be regarded as a kind of manual that will define the scope of our scope for a particular issue.