Appearance
WordPress
The simpledatalogs plugin connects a WordPress site in a minute: paste a public key, and page views start arriving. The browser SDK is bundled with the plugin; nothing loads from a CDN.
- WordPress 6.3+ and PHP 7.4+.
- No cookies.
- Never tracks wp-admin.
Install
- In WordPress, go to Plugins → Add New and search for simpledatalogs.
- Install and activate it.
Early access
The plugin isn't on wordpress.org yet. Until it is, download the ZIP from GitHub (Code → Download ZIP) and upload it under Plugins → Add New → Upload Plugin.
Set it up
- Open Settings → simpledatalogs.
- Paste a public key (
sdl_pub_…) and save. Secret keys are refused, because they must never appear in web pages. - Press Send test event. A success notice means
setup_testwas accepted.
What it sends
| Setting | Default | What you get |
|---|---|---|
| Page views | on | page_view on every public page, with path and title |
| Autocapture | off | Page views, sessions and JavaScript errors, from the bundled JavaScript SDK |
| Server-side events | off | Events sent from your server, picked one by one (below) |
Server-side events, once turned on:
| Event | When | Props |
|---|---|---|
user_registered | A new user registers | role |
user_logged_in | A user logs in | role |
comment_posted | A comment is posted | status, post_type |
order_completed | A WooCommerce order completes | total, currency, item_count, payment_method |
add_to_cart | A WooCommerce product is added to the cart | product_id, quantity |
Each server event gets its event_id and ts when it happens, and all of a request's events go in one non-blocking batch.
Your own events
Your theme can send its own events through the global client:
js
simpledatalogs.track('newsletter_signup', { form: 'footer' })Privacy and consent
- No cookies. Unsent events wait in the browser's
localStorage, and autocapture keeps its session id in the tab's session storage. - Do Not Track and Global Privacy Control turn tracking off, including your theme's own calls. This is on by default.
- Roles. Logged-in users with the roles you pick are never tracked, in the browser or on the server. Administrators are excluded by default.
- No personal data. No names, emails or IP addresses are put in events.
- Nothing is sent until you save a key.
Page caching
The plugin works with page caches. The script reads its settings from the page, and the privacy checks run in the browser. Role exclusion applies to logged-in users, whose pages caches usually skip.
Troubleshooting
| Test result | What to do |
|---|---|
401 | The key was refused. Check that it's a current public key; a new key takes a few seconds to go live |
| Could not be reached | Your server can't reach the ingest host. Leave Ingest host empty unless support gave you another |
| Anything else | Try again in a minute |
Next steps
- JavaScript SDK: the bundled client is version 0.3.0, so web mode and
data-trackclicks come with a later plugin release. - Privacy for senders: what to keep out of events.