بعد تنفيذ وحدات إعلانية جديدة في تطبيقك، عليك إعداد
اختبار أ/ب الذي سيساعدك على فهم مستوى أداء هذه الوحدات الإعلانية. ستحدد
المستخدمين الذين يجب استهدافهم في الاختبار بالإضافة إلى أهداف الاختبار. سوف
تحتاج إلى تحديد صيغ الاختبار (الوحدات الإعلانية المختلفة في تطبيقك) وتعيينها
مَعلمة Remote Config التي ستتحكّم في عرض
المختلفة في تطبيقك.
يستخدم Firebase A/B Testing المنتجات التالية لاختبار وتحليل
تأثيرات إضافة وحدة إعلانية إلى تطبيقك:
Firebase A/B Testing (هذه الخطوة) - تحديد الأهداف والمَعلمات القابلة للضبط لاختبارك
Google Analytics (يتم التشغيل من وراء الكواليس) — يقيس تأثير
الإعدادات
بدء اختبار أ/ب جديد
لبدء اختبار خاضع للرقابة لتحسين معدّل تكرار الإعلان، ابدأ بالتنقل.
إلى القسم A/B Testing في وحدة تحكّم Firebase. انقر على إنشاء.
التجربة، ثم اختَر Remote Config.
واجهة مستخدم وحدة تحكُّم Firebase تعرض كيفية بدء اختبار أ/ب باستخدام Remote Config"
class="لقطة شاشة">
إعداد الأساسيات
في قسم التفاصيل الأساسية، حدِّد اسم التجربة وقدِّم وصفًا لها.
واجهة مستخدم وحدة تحكّم Firebase تعرِض كيفية إعداد أساسيات اختبار A/B"
class="screenshot">
إعداد الاستهداف
في قسم الاستهداف، اختر تطبيق iOS أو Android الذي
المستهدفة.
حدِّد النسبة المئوية للمستخدمين الذين سيواجهون التجربة. لهذا الغرض
فيديو تعليمي، سيتم اختبار الوحدات الإعلانية الجديدة مع 30% من مستخدميك. لاحظ أن
فهذا لا يعني أن 30% من جميع المستخدمين سيشاهدون الوحدات الإعلانية الجديدة ذات
زيادة عدد مرات الظهور المحددة فهذا يعني أن 30٪ من المستخدمين لديك سيتعرضون
إلى الإعلانين البينيين الجديدين إلى جانب الوحدة الإعلانية الأساسية (
حاليًا).
واترك جميع الإعدادات الأخرى كإعدادات تلقائية.
واجهة مستخدم وحدة تحكُّم Firebase توضح كيفية إعداد استهداف اختبار أ/ب"
class="لقطة شاشة">
إعداد أهدافك
Firebase A/B Testing تتبّع مقياسًا أساسيًا لتحديد الصيغة التي تحقّق أفضل أداء، ولكنها تتيح لك أيضًا إضافة مقاييس ثانوية لفهم تأثير الإعدادات المختلفة في العوامل الأخرى المهمّة لتطبيقك.
بالنسبة إلى هذا الدليل التعليمي، يكون تحسين الأرباح المقدَّرة بقيمة AdMob هو الإعداد الأساسي.
الهدف، لذا حدده من القائمة المنسدلة.
(اختياري) إذا أردت أن تتتبّع A/B Testing مقاييس إضافية، مثل
إجمالي الأرباح المقدَّرة أو معدّلات الاحتفاظ المختلفة، اختَر هذه المقاييس من خلال
النقر على إضافة مقياس.
واجهة مستخدم وحدة تحكُّم Firebase توضح كيفية إعداد أهداف اختبار أ/ب"
class="لقطة شاشة">
إعداد الأسعار المتغيرة
الخطوة الأخيرة لإعداد اختبار أ/ب هي تحديد Remote Config
تتحكم في الوحدة الإعلانية التي سيتم عرضها للمستخدمين.
في قسم خيارات المنتج، أنشئ مَعلمة جديدة باسم.
INTERSTITIAL_AD_KEY عن طريق كتابته في حقل المَعلمة في
بطاقة المرجع
يمكنك إكمال إعداد قسم خيارات المنتج باستخدام الإعدادات التالية.
للمعلمة INTERSTITIAL_AD_KEY:
خيار المنتج خط الأساس: تم ضبط القيمة على رقم تعريف الوحدة الإعلانية الخاصة بالإعلان الحالي.
مع إعداد تحديد عدد مرات الظهور على 4 مرات ظهور لكل مستخدم لكل 10
دقائق
خيار المنتج الصيغة أ: تمّ ضبط القيمة على رقم تعريف الوحدة الإعلانية الخاصة بالإعلان الجديد.
مع إعداد تحديد عدد مرات الظهور 6 مرات ظهور لكل مستخدم لكل 10
دقائق
الصيغة الصيغة ب: القيمة مضبوطة على رقم تعريف الوحدة الإعلانية للوحدة الإعلانية الجديدة مع ضبط الحدّ الأقصى لعدد مرّات الظهور على 8 مرّات ظهور لكلّ مستخدِم كلّ 10
دقائق
في هذا الدليل التعليمي، ستعرِض صيغة الخط المرجعي الوحدة الإعلانية الحالية.
(4 مرات ظهور لكل مستخدم لكل 10 دقائق). سيكون الصيغة "أ" والصيغة "ب"
تعرض الوحدات الإعلانية الجديدة (6 و8 مرات ظهور لكل مستخدم لكل 10 دقائق،
على التوالي) إلى مجموعة فرعية صغيرة من المستخدمين. يتم التحكم في هذا من خلال
قيمة المعلمة، وهي رقم تعريف الوحدة الإعلانية المأخوذ من واجهة مستخدم AdMob. هذه
يتم تعيين قيم المعلمات هنا في Firebase A/B Testing، لكنها في الواقع
Firebase Remote Config الذي يرسل هذه القيم إلى رمز تطبيقك
ومعالجتها. سيتم إعداد Remote Config في الخطوة التالية.
واجهة مستخدم وحدة تحكُّم Firebase توضح كيفية إعداد صيغ اختبار أ/ب"
class="لقطة شاشة">
انقر على مراجعة للتأكّد من إعداد تجربتك على النحو المتوقّع. ومع ذلك،
قبل بدء التجربة، عليك تحديد طريقة تعامل رمز تطبيقك
مع قيم المَعلمات التي يتم تلقّيها من Firebase. انتقِل إلى الخطوة التالية لتحديد كيفية تعامل Remote Config مع المَعلمة INTERSTITIAL_AD_KEY
.
تاريخ التعديل الأخير: 2025-07-25 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2025-07-25 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["Step 2: Set up an A/B test in the Firebase console\n\n\u003cbr /\u003e\n\n|--------------------------------------------------------------------------------------------------------------------------------|\n| Introduction: [Optimize AdMob ad frequency using Firebase](/docs/tutorials/optimize-ad-frequency) |\n| Step 1: [Use AdMob to create new ad unit variants for testing](/docs/tutorials/optimize-ad-frequency/step-1) |\n| **Step 2: Set up an A/B test in the Firebase console** \u003cbr /\u003e |\n| Step 3: [Handle Remote Config parameter values in your app's code](/docs/tutorials/optimize-ad-frequency/step-3) |\n| Step 4: [Start the A/B test and review the test results in the Firebase console](/docs/tutorials/optimize-ad-frequency/step-4) |\n| Step 5: [Decide whether to roll out the new ad format](/docs/tutorials/optimize-ad-frequency/step-5) |\n\n\u003cbr /\u003e\n\nNow that you have new ad units implemented in your app, you need to set up an\nA/B test that will help you understand how these ad units perform. You'll define\nwhich users to target in the test as well as your testing goals. You'll also\nneed to define your test variants (the different ad units in your app) and set\nup the Remote Config parameter which will control the display of the\nvariants in your app.\n\nFirebase A/B Testing utilizes the following products to test and analyze the\neffects of adding an ad unit to your app:\n\n- Firebase A/B Testing (this step) --- define goals and configurable parameters for your test\n- Firebase Remote Config (next step) --- add logic to your code to handle the configuration of the parameters\n- Google Analytics (runs behind the scenes) --- measures the impact of the configurations\n\n**Initiate a new A/B test**\n\nTo initiate a controlled test for optimizing ad frequency, start by navigating\nto the *A/B Testing* section of the Firebase console. Click **Create\nexperiment** , then select **Remote Config**.\nFirebase console UI showing how to start an A/B test using Remote Config\" class=\"screenshot\"\\\u003e\n\n**Set up the basics**\n\nIn the *Basics* section, define the experiment name and provide the\nexperiment description.\nFirebase console UI showing how to set up the basics of A/B test\" class=\"screenshot\"\\\u003e\n\n**Set up targeting**\n\n1. In the *Targeting* section, select the iOS or Android app that the\n experiment will target.\n\n2. Set the percentage of users who will be exposed to the experiment. For this\n tutorial, the new ad units will be tested with 30% of your users. Note that\n this doesn't mean that 30% of all your users will see the new ad units with\n increased frequency caps; this means that 30% of your users will be exposed\n to the two new interstitial ads along with the baseline ad unit (your\n existing ad).\n\n Leave all other settings as their defaults.\n\nFirebase console UI showing how to set up the targeting of A/B test\" class=\"screenshot\"\\\u003e **Note:** Due to the different user behavior patterns observed from iOS and Android users, each A/B test can only target either the iOS or Android version of your app.\n|\n| To run the same test for both versions of your app, set up an experiment\n| for one version of your app, then duplicate the test settings in a second\n| experiment. In this second experiment, select the other version of your app\n| in the *Targeting* section.\n\n**Set up your goals**\n\nFirebase A/B Testing tracks a primary metric to determine the winning\nvariant, but it also allows you to add secondary metrics to understand the\nimpacts of different configurations on other important factors for your app.\n\n1. For this tutorial, *Estimated AdMob revenue* optimization is the primary\n goal, so select it from the dropdown menu.\n\n2. *(Optional)* If you want A/B Testing to track additional metrics, like\n *Estimated total revenue* or different retention rates, select those by\n clicking **Add metric**.\n\nFirebase console UI showing how to set up the goals of A/B test\" class=\"screenshot\"\\\u003e\n\n**Set up the variants**\n\nThe last step of configuring an A/B test is defining a Remote Config\nparameter that controls which ad unit will be shown to users.\n\n1. In the *Variants* section, create a new parameter named\n `INTERSTITIAL_AD_KEY` by typing it in the *Parameter* field of the\n *Baseline* card.\n\n2. Finish setting up the *Variants* section using the following settings\n for the `INTERSTITIAL_AD_KEY` parameter:\n\n - ***Baseline*** variant: *Value* set to the ad unit ID of the existing ad unit with the frequency cap setting of 4 impressions per user per 10 minutes\n - ***Variant A*** variant: *Value* set to the ad unit ID of the new ad unit with the frequency cap setting of 6 impressions per user per 10 minutes\n - ***Variant B*** variant: *Value* set to the ad unit ID of the new ad unit with the frequency cap setting of 8 impressions per user per 10 minutes\n\n For this tutorial, the *Baseline* variant will show the existing ad unit\n (4 impressions per user per 10 minutes). *Variant A* and *Variant B* will\n show the new ad units (6 and 8 impressions per user per 10 minutes,\n respectively) to a small subset of users. This is controlled by the\n parameter's value which is the ad unit ID taken from the AdMob UI. These\n parameter values are set here in Firebase A/B Testing, but it's actually\n Firebase Remote Config that sends these values to your app's code for\n handling. You'll set up Remote Config in the next step.\n | **Note:** In your own future tests, if you set up various experiments and variants, we recommend giving variants meaningful names to easily track the test results later on.\n\nFirebase console UI showing how to set up the variants of A/B test\" class=\"screenshot\"\\\u003e\n\nClick **Review** to make sure your experiment is set up as expected. However,\nbefore you can actually start the experiment, you need to define how your app's\ncode will react to the parameter values received from Firebase. Proceed to the\nnext step to implement how Remote Config handles the `INTERSTITIAL_AD_KEY`\nparameter.\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\n\u003cbr /\u003e\n\n[arrow_back_ios**Step 1** : Use AdMob to create new ad unit variants](/docs/tutorials/optimize-ad-frequency/step-1)\n[**Step 3** : Handle Remote Config parameter valuesarrow_forward_ios](/docs/tutorials/optimize-ad-frequency/step-3)\n\n\u003cbr /\u003e\n\n*** ** * ** ***"]]