WooCommerce Google Analytics Integration


This plugin provides the integration between Google Analytics and the WooCommerce plugin. You can link a referral to a purchase and add transaction information to your Google Analytics data. It also supports Global Site Tag, Universal Analytics, eCommerce, and enhanced eCommerce event tracking.

Starting from WooCommerce 2.1, this integration is not packaged with WooCommerce and is only available by using this plugin.

Contributions are welcome via the GitHub repository.


  • Google Analytics設定画面


  1. プラグインのファイルを自分のコンピューターにダウンロードして、解凍します。
  2. FTPソフトを利用したり、サーバーの管理画面からワードプレスの wp-content/plugins/ ディレクトリに解凍したプラグインフォルダをアップロードします。
  3. WordPress の管理画面のプラグインメニューからプラグインを有効化します。
  4. Don’t forget to enable e-commerce tracking in your Google Analytics account: https://support.google.com/analytics/answer/1009612?hl=en

Or use the automatic installation wizard through your admin panel, just search for this plugin’s name.



This plugin will add the settings to the Integration tab, found in the WooCommerce → Settings menu.

サイト上にコードが表示されません。 どこにあるのですか?

We purposefully don’t track admin visits to the site. Log out of the site (or open a Google Chrome Incognito window) and check if the code is there for non-admins.

Also please make sure to enter your Google Analytics ID under WooCommerce → Settings → Integrations.


Duplicate Google Analytics code causes a conflict in tracking. Remove any other Google Analytics plugins or code from your site to avoid duplication and conflicts in tracking.

My settings are not saving!

Do you have SUHOSIN installed/active on your server? If so, the default index length is 64 and some settings on this plugin requires longer lengths. Try setting your SUHOSIN configuration’s “max_array_index_length” to “100” and test again.



You can prevent Google Analytics from tracking you by clicking the following link. An opt-out cookie will be set, which will prevent you being tracked when visiting this website in the future:
<a href="javascript:gaOptout()">Deactivate Google Analytics</a>.

view raw


hosted with ❤ by GitHub



2023年3月10日 1 reply
The support forum is full of people complaining that page views are not sent correctly using GA4 - which everyone will be using seeing as universal is now being imminently retired. The only advice given by plugin devs is to disable "add to cart" events, or modify the plugin code directly to fix their fault plugin logic. This issue has been around for 2 years.
2022年11月21日 1 reply
This is the most easiest setup for Google Analytics ever. All it asks for your ID, and it will show up everything on your Google Analytics! On your Global Site Tag, Universal Analytics, eCommerce, and more! No any kind of snippet or codes!
I see the faq about SUHOSIN and maybe that's the cause. I think its possible to create plugins that don't require changes to server config just to save options. And this plugin is as useless as the rest of the analytics plugins if I can't track ecommerce.
2021年9月23日 1 reply
I installed this plugin, configured the settings and it did not work. Didn't even bother to try and figure it out. Deactivated it and removed it from my site.


WooCommerce Google Analytics Integration はオープンソースソフトウェアです。以下の人々がこのプラグインに貢献しています。


“WooCommerce Google Analytics Integration” は11ロケールに翻訳されています。 翻訳者のみなさん、翻訳へのご協力ありがとうございます。

“WooCommerce Google Analytics Integration” をあなたの言語に翻訳しましょう。

開発に興味がありますか ?

コードを閲覧するか、SVN リポジトリをチェックするか、開発ログRSS で購読してみてください。


1.8.1 – 2023-05-09

  • Fix – Fatal error when running with Elementor.
  • Tweak – WC 7.7 compatibility.

1.8.0 – 2023-05-02

  • Add – Create WordPress Hook Actions for Google Analytics.
  • Add – Implement tracking with Actions Hooks.
  • Dev – Implement JS Build (ES6) and JS Lint.
  • Dev – Implement Javascript Building.

1.7.1 – 2023-04-12

  • Fix – Bug with tracking enhanced ecommerce.

1.7.0 – 2023-03-28

  • Dev – Load scripts via wp_register_scripts and wp_eneuque_js.
  • Fix – Avoid duplication of Google Tag Manager script.
  • Tweak – WC 7.6 compatibility.
  • Tweak – WP 6.2 compatibility.

1.6.2 – 2023-03-07

  • Tweak – WC 7.5 compatibility.
  • Tweak – WP 6.2 compatibility.

1.6.1 – 2023-02-15

  • Tweak – WC 7.4 compatibility.

1.6.0 – 2023-01-31

  • Add – Common function for event code.
  • Fix – Add PHP unit tests.
  • Fix – Feature/consistency across gtag implementation.
  • Fix – Fix inconsistencies across item data in events.
  • Fix – Fix usage of tracker_var() in load_analytics().

1.5.19 – 2023-01-11

  • Fix – undefined WC constant.
  • Tweak – WC 7.3 compatibility.

See changelog for all versions.