Shortcodes

What is a Shortcode in WordPress?

Applies to SlimStat 6.0.0 · checked

A WordPress shortcode is text in square brackets that WordPress replaces with generated content in a supported context. SlimStat Free 6 provides shortcodes for selected analytics summaries; you do not need Pro for the basic shortcode API.

Start with SlimStat → Shortcodes to browse reports and preview your data before copying a shortcode.

Add a SlimStat shortcode

  1. Edit a page and add a Shortcode block.
  2. Enter the shortcode below.
  3. Preview the page and confirm its output before publishing.
[slimstat f="count" w="id"][/slimstat]

This counts recorded pageviews in the default report date range, normally the current month. It does not mean unique visitors or all-time traffic. SlimStat must be active and the page context must execute shortcodes; a Code block displays the text instead.

Choose what readers can see

A shortcode displays analytics to anyone who can access the page. Use aggregate counts or suitable page summaries, not private visitor identifiers. A cached page can show an older count until its cache refreshes.

For dimensions, date ranges and filters, see the SlimStat shortcode reference and worked examples. WordPress also documents how the Shortcode API works.