virling Pricing Self-host Demo Changelog Agencies GitHub Start free trial
integrations / woocommerce for agencies

Show each WooCommerce client which channel drives their sales.

For agencies that build or market client stores on WordPress and WooCommerce. Virling reads each store's orders with a read-only REST API key, credits every paid order to the visit that brought the buyer, and keeps each client on a site of its own with a branded report that opens without a login. Open source under AGPL, hosted or self-hosted.

Start free trial Virling for agencies

A WooCommerce client wants to know which ads and emails paid for themselves. The order lives in WordPress and the click lives in your campaign tools. Virling joins the two per store, using the visitor ID a short snippet saves on each order, so the answer comes from the client's own orders. Client reports, grouping and pricing for every provider are on Virling for agencies.

What your agency gets

  • A site for every store. Each client domain gets its own tag and its own WooCommerce key, and revenue never mixes between clients. Sites given the same client name sit together in the site switcher and on All clients, which totals visitors and revenue for the last 30 days per client.
  • Paid orders by channel. The Channels card shows visitors, revenue and revenue per visitor per channel, down to source and UTM campaign, and Payments lists each order with the channel that got the credit. Refunds lower an order's revenue, and WooCommerce Subscriptions renewals keep the channel of the first payment.
  • Reports clients open without an account. Each site has a client link with your agency name, logo and colours that you can revoke at any moment, and a weekly email of the same report to as many as 10 addresses.
  • Public dashboard. An optional read-only page for clients who want to show their numbers in public. It never shows emails or customer IDs.
  • API and MCP. A single API key reads every client site, and the same key lets an AI assistant query them through the MCP server.
  • Team members for agency staff only, since a member sees and manages every site on the account.

WooCommerce client setup

  • Who creates the REST API key. The client, or whoever holds an administrator login on their WordPress, adds it under WooCommerce, Settings, Advanced, REST API with Permissions set to Read. A key belongs to the WordPress user picked when it is made, so choose the client's own account rather than a login made for agency staff. Virling sends the consumer key and secret only to the store address you enter, at /wp-json/wc/v3/, so the store needs https and pretty permalinks.
  • Plugin or script tag. The Virling WordPress plugin adds the tag to every page, survives theme updates and skips logged-in administrators by default; enter the Virling server and site domain under Settings, Virling. Without it, paste the tag before </head> in the theme's header.php, in a child theme so an update does not wipe it. Either way, the order snippet from the WooCommerce integration goes separately into functions.php or a snippets plugin, and covers the classic and the block checkout. If a client is still comparing tools, see the WooCommerce attribution plugin checklist.
  • Staging and live sites. Connect only the live store. The tag keeps events from the site's domain and its subdomains, so a copy on staging.clientshop.com would add its visits to the live site: deactivate the plugin or remove the tag there. Pages on a different host are dropped, and so is localhost unless the tag has data-dev. To test on staging, add it as a separate Virling site.
  • Caching. Keep cart and checkout out of any page cache, and exclude v.js from script combining and delaying, so the snippet sees the visitor cookie at checkout. See caching and CDNs.
  • What Virling reads from an order. Its status, total, currency, paid date, refunds, customer ID, billing email and the virling_vid meta field. Processing and completed orders count as paid, failed and cancelled ones as failed, and pending or on-hold orders, such as an unpaid bank transfer, wait until they move on. Orders with a $0 total are skipped, and line items, addresses and order notes are not stored.

Before the first call

Collect these from the client before setup starts.

  • The live address. The domain shoppers use, the timezone for reports, and any staging addresses, so you know where the tag must not go.
  • A way into WordPress. Someone who can install a plugin or edit the theme, and add the order snippet. Some managed hosts turn off the theme file editor, so a snippets plugin or file access may be the only route.
  • The Read key. A consumer key and secret with Read permission, shared through a password manager or another private channel, plus the store's https address.
  • Gateways and order sources. Which payment gateways and express buttons the store uses, and whether orders are also made in the admin or by another system. Orders created outside the classic and block checkout carry no visitor ID, so plan a test order with each gateway.
  • WooCommerce Subscriptions. Whether it is installed, because renewals then keep the channel of the first order and subscription status feeds Retention.
  • Spend and recipients. Monthly spend per channel, for Profit by channel, and the addresses, up to 10, that should get the weekly email.

Set up a client store

  1. Create the site. Use + Add a site with the live domain and timezone, then type the client's name under Client in site settings.
  2. Add tracking. Install the plugin or paste the tag, then add the order snippet so every new order stores the visitor ID.
  3. Connect the store. In the site's payment setup, paste the key as ck_...:cs_... with the store's https address. The first import reads orders from the last 90 days, and new orders follow every minute.
  4. Place a test order. In a private window, open the store through a tagged link and check out with the gateway in test mode or with Cash on delivery. The order's custom fields should include virling_vid, and after the next sync Payments shows it under the tagged channel.
  5. Send the client view. Add branding under Client report, create a client link, and switch on the weekly email if the client wants it.

Campaign links without UTM tags arrive as Direct, so build them with the UTM builder; WooCommerce UTM tracking covers the details.

Monthly client reports

Each week the client report and email give one line per channel compared with the week before. For a monthly meeting, set the dashboard range to the month: the Channels card has revenue and revenue per visitor, and opening an order in Payments shows the visits that led to it. With the client's monthly spend per channel saved in site settings, Profit by channel adds spend, profit and return per dollar.

Lay the numbers out with the client marketing report template, and see how to prove marketing ROI to clients for the monthly method. Download PDF saves the report as a file for your own deck.

When a client leaves

  • Export first. Download PDF saves the report. The Read API returns the site's payments as JSON, 200 per call with an offset for paging, and breakdowns of up to 1,000 rows. A hosted site cannot be exported or moved to another account as a whole.
  • Disconnect in Virling. Disconnect in site settings deletes the stored consumer key and secret and stops the sync. Orders already imported stay in the reports.
  • Revoke the key in WooCommerce. Ask the client to open WooCommerce, Settings, Advanced, REST API and revoke the key made for Virling.
  • Turn off sharing. Revoke link under Client link stops the report at once, and turning off Weekly email under Change schedule stops the email. Revoke any API key you shared too, since keys read every site on the account.
  • Clean up WordPress. Deactivate the plugin or remove the tag, and take the snippet out of functions.php. The virling_vid field stays on past orders and does nothing without Virling.
  • Delete the data. On the hosted plan, email hello@virling.com and the site is deleted within 30 days. On a self-hosted server, the admin panel deletes it at once.

Open source

The code is open source under AGPLv3 on GitHub. Run it hosted, or self-host it with every feature on your own server. In a load test on 2026-10-31, in a container limited to one vCPU and 1 GB of RAM, it ingested 100,000 pageviews at 2,829 a second with none failed, and answered dashboard queries at 0.6 to 7.6 ms median.

Frequently asked questions

How do agencies show WooCommerce clients which channel drives sales?

Give each client store its own Virling site, add the tag and the order snippet that saves the visitor ID, and connect the store with a Read REST API key. Every paid order is credited to the channel and campaign of the visit before it, and the client opens the result through a report link with no login.

Does every WooCommerce store need its own Virling site?

Yes. Each domain has its own tag, its own order snippet and its own REST API key, so orders never mix between clients. Give the sites one client name to group them under All clients.

Do WooCommerce clients need a Virling login to see reports?

No. The client link opens that one site's report with your branding, and the weekly email sends it to up to 10 addresses. Revoking the link turns it off right away.

Can Virling edit orders or products in a client's store?

No. The key has Read permission, so WooCommerce refuses writes, and Virling only sends read requests. It never creates, changes or refunds anything.

Why does an order paid by bank transfer show up late?

Pending and on-hold orders are not imported. A bank transfer or cheque order waits on hold until the client marks it Processing or Completed, then Virling imports it, credited to the visit saved on the order. An order paid more than about 10 minutes after it was created can take up to 6 hours to show.

Should the plugin and snippet go on the client's staging site?

Only if staging is its own Virling site. A staging copy on a subdomain of the live domain adds its visits to the live site, and connecting the staging store would mix test orders into the client's revenue. Connect the live store only, and turn the tag off on staging.

Full guide: Run Virling for client sites and WooCommerce in the docs.

Start free trial