Knowledge Base

How do I integrate legal shortcodes into my website?

Real Cookie Banner helps you meet the legal requirements for a cookie banner by providing legal shortcodes (e.g. to change privacy settings). You should make sure to include these in your privacy policy and in your footer so that your visitors can always access them and exercise their rights.

Shortcodes are small functions that you can easily insert into the text of your WordPress website. And this is how it works:

  1. In your WordPress backend, click on Cookies in the menu on the left.
  2. Go to the Consent > Legal Shortcodes.
Real Cookie Banner Legal Shortcodes
  1. Here you will find the three columns Change privacy settings, Privacy settings history and Revoke consent. For all three functions, Real Cookie Banner generates shortcodes that you should integrate into your website. Optionally, you can edit them (link or button, displayed text, etc.).
  2. Scroll down. At the bottom of the page you will find, among other things, an explanation of the legal necessity of the generated shortcodes.
Shortcodes Legal Basis
  1. You can copy a shortcode by clicking Copy to clipboard.
Copy Shortcode
  1. Now select Pages > All Pages from the left-hand menu and edit the page on which the functionalities are to be made available to your visitors. In our case, the page is called Privacy Policy.
WordPress Select Pages
  1. Here you can insert the shortcode as text at any position. You do not have to include the shortcode in a special block/element and you do not have to link it additionally.
  1. Save the changes.

The shortcode is converted into the respective button or link to be inserted when viewing the page on which it was inserted. We have placed the shortcodes in the section on the Use of Cookies. You can also take a look at our privacy policy.

Privacy Policy devowl

Do I have to place the shortcodes on every page?

It has not been conclusively clarified whether visitors to your website must be able to exercise their right to change and revoke their consent on every sub-page or only in the privacy policy, for example. In any case, you are on the safer side if you place the shortcodes e.g. in the footer on each subpage.

Do I have to create a separate page for the integration of the shortcodes?

No, you don’t need to create a separate page to embed the shortcodes into your website. In most cases, you should add them to the existing privacy policy in the appropriate place.

Important: Legal pages such as the privacy policy must always be accessible to the visitor and are not allowed to be covered by a cookie banner or other pop-ups.

Can I use legal links without a shortcode?

For example, if your theme does not support shortcodes in the footer, you can simply create a link with the following address (you do not need to prefix it with https:// or anything similar):

  • #consent-change: Change privacy settings
  • #consent-history: Privacy settings history
  • #consent-revoke: Revoke consents

In HTML, it could look like this:

<a href="#consent-change">Change privacy settings</a>

WordPress Plugins by devowl.io

Find helpful articles

Topics