WordPress Plugin
Install and connect the Nashra WordPress plugin with an API key from Settings → API keys to sync WordPress users and WooCommerce customers into Nashra automatically — tags, purchase data for segmentation, the [nashra_optin] shortcode, the activity log, and troubleshooting a failed sync.
What it syncs
The Nashra plugin for WordPress connects your site to your Nashra workspace and keeps your subscriber list current without manual exports. New WordPress registrations, your existing users, and — if you run WooCommerce — your customers all sync in as Nashra subscribers, tagged by source so you can segment them later.
Every synced WordPress user gets the tag WordPress. WooCommerce customers additionally get WooCommerce. The first time your connection succeeds, the plugin also creates matching WordPress Users and Customers (WooCommerce) segments in Nashra automatically, so there's a working segment to send to right away. See Audience for how tags and segments work.
The plugin also has a separate, optional Post Sync feature that pulls your published Nashra posts into WordPress on a schedule, configured under its own tab in the plugin settings. It copies every post that's live on the web, including unlisted ones — so an unlisted post can end up listed on your WordPress site. This page covers syncing subscribers and customers into Nashra — the direction most sites use it for.
Installing and connecting
Upload and activate
Upload the nashra folder to /wp-content/plugins/, then activate it from the Plugins menu. Requires WordPress 6.2 or later and PHP 7.4 or later (tested up to WordPress 6.9).
Open Settings → Nashra
The plugin adds its own settings page under WordPress's Settings menu.
Enter your connection details
Enter your Nashra instance URL (defaults to https://app.nashra.ai) and an API key, created in Nashra under Settings → API keys. New keys expire after 90 days unless you pick another option — choose No expiry for the plugin's key, or note the date so syncing doesn't stop. See Authentication.
Test the connection
Click Test Connection. This calls GET /tags against your workspace to confirm the key works, and creates the default segments if it succeeds.
Configure sync
Set the opt-in checkbox default, choose which roles sync, and turn on WooCommerce integration if you need it.
What syncs, and when
- New registrations sync the moment someone signs up, if the opt-in checkbox on the registration form is checked.
- Existing users sync in background batches shortly after you activate the plugin. Re-trigger anytime from Settings → Nashra: Sync Now picks up anyone not yet synced; Re-sync All clears sync status first and starts over.
- WooCommerce customers — including guest checkouts — sync when an order reaches Processing or Completed, and when someone registers through WooCommerce's My Account page, if WooCommerce integration is enabled and the opt-in box is checked.
- Role filtering — under Sync Roles, choose which WordPress roles are eligible to sync. Leave every role unchecked to sync all of them.
The opt-in checkbox only gates new registrations and WooCommerce checkouts going forward — it has no effect on bulk sync. Bulk sync (on activation, Sync Now, or Re-sync All) syncs every existing user matching your role filter, whether or not they ever saw the checkbox. And because the plugin adds people through the API, they're subscribed right away — your double opt-in setting doesn't send them a confirmation email. Confirm your existing users have agreed to receive email before turning bulk sync on.
Purchase data for segmentation
For WooCommerce customers with at least one order, the plugin also sends purchase data as custom fields, created automatically in Nashra the first time WooCommerce sync runs:
| WooCommerce data | Nashra custom field | Type |
|---|---|---|
| Number of orders | Total Purchases (order_count) | Number |
| Lifetime spend | Total Spent (total_spent) | Number |
| Most recent order date | Last Order Date (last_order_date) | Date |
Use these fields to build segments once they exist — for example, high spenders (total_spent above a threshold) for a loyalty send, or stale buyers (last_order_date before a cutoff) for a win-back campaign.
Opt-in checkbox and shortcode
The same opt-in checkbox — its label and default state configurable under Settings → Nashra — appears on the WordPress registration form, the WooCommerce checkout, and WooCommerce's My Account registration form.
To collect subscribers anywhere else on your site, use the [nashra_optin] shortcode. Defaults live under the plugin's Opt-in Form tab; override any of them per placement with shortcode attributes:
| Attribute | What it controls |
|---|---|
title | Heading text |
subtitle | Supporting text |
placeholder | Email field placeholder |
button | Submit button label |
tags | Comma-separated tags applied on signup (default Newsletter) |
accent_color | Button/accent color, as a hex value |
Example: [nashra_optin title="Get updates" tags="footer,newsletter"]
Activity log
Settings → Nashra → Activity Log records connection tests, sync successes and failures, and bulk sync start/complete events, filterable by type. Entries older than 30 days are cleared automatically. It's the first place to check when something isn't syncing.
Troubleshooting
Test Connection fails
Test Connection calls GET /tags with your key — a failure here usually means the key or instance URL is wrong. Confirm the URL matches your Nashra instance (default https://app.nashra.ai), and that the key still appears under Nashra's Settings → API keys without a past date in its Expires column. If your WordPress host blocks outbound HTTPS requests, the connection fails the same way — check with your host once the key and URL both check out.
Users aren't syncing
Check the Activity Log first. Repeated whole-batch failures pause bulk sync automatically after three in a row — usually caused by an expired or deleted key — and it stays paused until you add a working key and click Sync Now again. For new registrations or WooCommerce orders specifically, confirm the opt-in checkbox was checked; without it, nothing is sent. API errors never block registration or checkout on your site — they're logged, not shown to the customer, so a sync failure won't look like anything went wrong to the person signing up.
Role filter is excluding people
If you've selected specific roles under Sync Roles, only users with those roles sync — everyone else is skipped without an error. Leave the list empty to sync every role.