Blog

How to Set Up GA4 on a Cafe24 Store, Step by Step

Imagefactory · Published 2026-09-16 · Updated 2026-09-18

GA4 (Google Analytics 4) is Google's free analytics tool that shows which ad or search term brought a visitor in, which pages they viewed and where they bought. To add it to a Cafe24 store you create a GA4 property, paste the GTM (Google Tag Manager) code into Cafe24's Direct code input, then publish the GA4 tag and a purchase event from GTM. It takes about an hour the first time, and the steps below go in order.

What does GA4 show you?

The statistics in the Cafe24 admin summarize how many people visited today and how much they spent. GA4 shows where each visitor came from and what they were doing when they left, broken down by path. Once you spend on ads, that difference is money.

QuestionCafe24 admin statisticsGA4
Which ad or search term did the buyers come from?Visit counts per source onlyPurchases and revenue per channel and campaign in the Acquisition reports
Which page did visitors leave from?Page view counts onlyExits and time on page per page in the Engagement reports
How many reached the cart but never paid?-Drop-off per step in the purchase journey report
Does it connect to Google Ads performance?-Link the Ads account and import GA4 purchases as Ads conversions

GA4 is free. You need the store owner's Google account, Cafe24 admin access and the five steps below.

GA4 propertycopy the G- IDGTM container2 code snippetsCafe24 code inputHead · BodyGA4 tag + purchasepublish GTMVerify & inviteRealtime · Access
The five steps to put GA4 on a Cafe24 store — the property and GTM live in Google's screens, the paste happens in the Cafe24 admin, and the rest is back in GTM and GA4.

Before you start

First check whether a tag is already on the store. Open the page source of your storefront (Ctrl+U on Windows, Cmd+Option+U on Mac) and search for the strings below.

Search forMeaningIf found
G-GA4 measurement IDGA4 already exists. Find out which Google account owns the property first
GTM-GTM container IDGTM is already installed. Add the GA4 tag inside that container instead of installing another
AW-Google Ads conversion tagOnly the Google Ads link from Cafe24's Google & YouTube channel is set up. There is no GA4 yet

Linking Google Ads in the Google & YouTube channel does not install GA4. The conversion tag that app adds counts conversions for Google Ads, and although it leaves a _ga cookie in the browser, it sends nothing to a GA4 property. The real test is whether the source contains a measurement ID starting with G-.

1) Create the GA4 property

Create the property under the store owner's Google account and invite the agency and analyst afterwards. If the agency creates it under its own account, the data does not stay with the advertiser when the contract ends.

  1. Sign in to Google Analytics and press Start measuring. Use the company name as the account name. If an account already exists, go to AdminCreateProperty.
  2. On the property screen, enter a property name (1), then change the reporting time zone (2) to South Korea and the currency (3) to South Korean Won. The defaults are United States and US dollars, which shift report dates and revenue units if left alone.
Google Analytics create-property screen. The property name field, the reporting time zone set to South Korea and the currency set to South Korean Won are marked 1, 2 and 3
Enter the property name (1) and switch the reporting time zone (2) and currency (3) to South Korea. The defaults are United States and US dollars.
  1. Choose your business details and objectives, press Create and accept the terms of service.
  2. Pick Web as the platform, enter your primary domain as the website URL and the store name as the stream name, then press Create stream. Leave enhanced measurement switched on.
  3. Copy the Measurement ID (starting with G-) shown in the stream details. You need it in step 3).

The steps follow Google's Analytics setup help.

2) Create a GTM container and install it in Cafe24

Pasting a bare gtag with the measurement ID does collect page views. But once you add the purchase event, a Meta pixel or Google Ads enhanced conversions, managing everything in GTM is easier. You never have to reopen the Cafe24 screen to change a tag.

  1. In Google Tag Manager press Create Account. Use the company name as the account name (1), South Korea as the country (2), the store domain as the container name (3) and Web as the target platform (4). Press Create and accept the terms.
Google Tag Manager add-new-account screen. The account name, the country set to South Korea, the container name and the Web target platform are marked 1 to 4
Enter the account name (1), country (2) and container name (3), then choose Web (4) as the target platform.
  1. A window with two installation snippets opens right away. If you closed it, reopen it under AdminInstall Google Tag Manager.
  2. In the Cafe24 admin go to Store settingsBasic settingsStore infoSearch engine optimization (SEO), open Advanced settings at the bottom and find Direct code input.
GTM installation snippetCafe24 Direct code input
First snippet (starts with <script>)Head area
Second snippet (starts with <noscript>)Body area
  1. Paste into both the PC store tab and the mobile store tab, then press Save. According to Cafe24's help article, code in the Head area is added inside the head tag of every page.
  2. Leave the Google & YouTube channel app's conversion tag in place. Adding another Google Ads conversion tag inside GTM would count each conversion twice.

3) Create the GA4 tag in GTM and publish

  1. In the GTM workspace open TagsNew and choose Google Tag as the tag type.
  2. Paste the measurement ID from step 1) into Tag ID.
  3. Choose Initialization - All Pages as the trigger.
  4. Press Preview, open your store URL and check that Tag Assistant shows the Google tag as fired.
  5. Press SubmitPublish. Nothing reaches the site until you publish.
  6. When your own visit appears under GA4 ReportsRealtime, the installation is done.

The tag setup follows Google's guide to the Google tag in GTM.

4) Add the purchase event

Up to this point you see visits and page views but no revenue. Cafe24 exposes the order number, paid amount and ordered products as JavaScript variables on the order-complete page (/order/order_result.html). Sending those values as a GA4 purchase event puts revenue and purchased items into GA4. You create two tags and two triggers in GTM.

  1. Create a Custom HTML tag with the code below. Its trigger is Page View with the condition Page Path contains order_result.
<script>
  (function () {
    var d =
      (window.CAFE24 && CAFE24.FRONT_EXTERNAL_SCRIPT_VARIABLE_DATA) ||
      window.EC_FRONT_EXTERNAL_SCRIPT_VARIABLE_DATA;
    if (!d || !d.order_id) return;
    var items = (d.order_product || []).map(function (p) {
      return {
        item_id: String(p.product_no),
        item_name: p.product_name,
        price: Number(p.product_price),
        quantity: Number(p.quantity),
      };
    });
    window.dataLayer = window.dataLayer || [];
    dataLayer.push({ ecommerce: null });
    dataLayer.push({
      event: "purchase",
      ecommerce: {
        transaction_id: String(d.order_id),
        value: Number(d.payed_amount),
        currency: "KRW",
        shipping: Number(d.total_basic_ship_fee || 0),
        items: items,
      },
    });
  })();
</script>
  1. Create a Custom Event trigger with the event name purchase.
  2. Create a Google Analytics: GA4 Event tag. Enter the measurement ID, set the event name to purchase, tick Send Ecommerce data and keep the data source as Data Layer. Use the purchase trigger from 2).
  3. Place one test order in Preview mode. When GA4 AdminDebugView shows the purchase event with a transaction ID, press SubmitPublish.

The variable names (order_id, payed_amount, order_product) are the values Cafe24 places on the order-complete page. While in preview, type CAFE24.FRONT_EXTERNAL_SCRIPT_VARIABLE_DATA in the browser console once to confirm the values are there before publishing. The event format follows Google's GA4 ecommerce events reference, and the Cafe24 variables follow a Cafe24 GA4 ecommerce setup walkthrough.

Naver Pay orders never pass through this page. That is why the GA4 purchase count is always lower than the order count in the Cafe24 admin.

5) Verify and invite your analyst

  1. In GA4 go to AdminProperty access management, press + and enter the analyst's email. Give Editor to the person who sets up tags and events, and Viewer to someone who only reads reports. Roles are explained in Google's access management help.
  2. Under AdminKey events, mark purchase as a key event.
  3. Under AdminProduct linksGoogle Ads links, link the Google Ads account. Once linked, Google Ads can import the GA4 purchase as a conversion. Because the Cafe24 app's tag already counts checkout completions, keep the imported conversion as a secondary conversion to avoid double counting. The steps follow Linking GA4 and Google Ads.

Checklist

What to checkScreenExpected
Tag is on the siteStorefront page sourceCode starting with GTM- appears in both head and body
GTM is publishedGTM → VersionsThe latest version shows as published
Data is arrivingGA4 → Reports → RealtimeYour own visit shows as 1 user
Purchases are capturedGA4 → Admin → DebugViewAfter a test order, the purchase event carries a transaction ID
Time zone and currencyGA4 → Admin → Property detailsSouth Korea and South Korean Won
Analyst accessGA4 → Admin → Property access managementThe analyst's email is listed as Editor

Five things that commonly go wrong

Nothing shows in Realtime. Most often GTM was never published with SubmitPublish, or the code went into the PC store tab only and the mobile tab was skipped. Turn off ad-blocking extensions and reload in an incognito window.

The purchase event stays at zero. Check that the Custom HTML tag's trigger condition is order_result. Place a test order in preview, confirm that purchase lands in the dataLayer, then check whether the container was published.

GA4 purchases are lower than Cafe24 orders. Naver Pay and Kakao Pay orders skip the Cafe24 order-complete page. The two numbers can never match, so compare them as a trend.

A _ga cookie exists but GA4 is empty. That cookie comes from the Merchant Center tag added by the Google & YouTube channel app. If the source has no measurement ID starting with G-, GA4 is not installed. Cafe24's own Cafe24 Analytics in the admin is a separate statistics tool as well.

I already pasted gtag and pixels into Direct code input. Google says to keep either the Google tag snippet or Tag Manager, not both; with both, page views are counted twice. If you are moving to GTM, build the Google tag and events in GTM first, delete the gtag from Direct code input, then publish the GTM version. Meta and TikTok pixels have their own menus in Cafe24's channel settings, so take them out of Direct code input and move them there. The order follows the Tag Manager migration guide.

Google Ads conversions doubled. The app's conversion tag and an Ads conversion tag added in GTM are counting the same checkout twice. Remove the Ads conversion tag from GTM. Setting the app's page-view conversion action to secondary in Google Ads keeps the conversion column from inflating.

An agency installing this for you needs Cafe24 admin access. Instead of handing over the master login, create a Cafe24 sub-operator account. Google Ads access is covered in requesting agency access to Google Ads, and the case where the Cafe24 app cannot see your Ads account in when Cafe24 can't find your Google Ads account.

Where Imagefactory helps

Imagefactory builds and runs an AI marketing platform and manages ad accounts for clients. When you hand over ad operations, the GA4 and GTM installation, the purchase event and the Google Ads conversion link are set up within the first week, and the conversion tracking on every linked ad account is watched so it does not silently break. GA4 tells you which visitors buy and where they came from. What moves results after that is which creatives run on which channel at what budget, and that is the operation Imagefactory takes on.

Frequently asked questions

I already pasted gtag into Direct code input. Do I also add GTM?

Keep only one. Google says a site with both the Google tag snippet and Tag Manager double counts page views. To move to GTM, build the tags in GTM first, delete the gtag from Direct code input, then publish.

Cafe24 already has admin statistics. Why do I need GA4?

The Cafe24 statistics summarize visits and revenue. GA4 shows which ad or search term brought each buyer and which pages they passed through, and it links to Google Ads so purchases can be imported as conversions. It is free.

Where do I paste the GA4 tag in Cafe24?

Store settings → Basic settings → Store info → Search engine optimization (SEO) → Advanced settings → Direct code input. Put the first GTM snippet in the Head area and the second in the Body area, and save both the PC and mobile store tabs.

Should I paste gtag directly or use GTM?

Use GTM. A bare gtag only sends page views, while GTM lets you add the purchase event and other pixels later without reopening Cafe24. Tag changes are published from GTM instead.

I linked Google Ads in Cafe24. Is GA4 installed too?

No. The conversion tag from the Google & YouTube channel sends data only to Google Ads and Merchant Center. GA4 needs its own property and a tag with the G- measurement ID placed on the store yourself.

GA4 purchases don't match my Cafe24 order count. Why?

Naver Pay orders skip the Cafe24 order-complete page, so no purchase event fires for them. Ad blockers and declined consent drop some visits too. Compare the two numbers as a trend rather than expecting them to match.

How do I invite an analyst or agency to GA4?

In GA4 go to Admin → Property access management, press the plus button, enter the email and pick a role. Choose Editor for someone who sets up tags and events, and Viewer for someone who only reads reports.

Related reading

Looking for someone to handle GA4 setup through Google Ads conversion linking?

Tag installation, the purchase event and Ads conversion import, done within the first week. A Cafe24 sub-operator account is all it takes to start.

Ask about managed ads