Site icon DataForSEO

What is “include_subcategories” in the Google Categories For Domain endpoint?

DataForSEO Labs Categories For Domain endpoint provides you with Google product or service categories that include keywords the domain ranks for in search. You will also obtain general rankings and traffic data for the keywords under a certain category.

You can get the full list of categories available for all DataForSEO Labs endpoints by calling the following endpoint:

GET https://api.dataforseo.com/v3/dataforseo_labs/categories

Generally speaking, all category codes are divided into two types: superordinate category and subcategory. Superordinate category is a name of a group of subcategories and displays in the "category_code_parent" field in the Categories endpoint response.

For example:
"category_code": 10178,
"category_name": "Apparel Accessories",
"category_code_parent": 10021

Where category_code_parent corresponds to:
"category_code": 10021,
"category_name": "Apparel",
"category_code_parent": null

10021 is a superordinate category, and 10178 is a subcategory which belongs to the “Apparel” group.

The Categories For Domain output is grouped from the largest to the smallest amount of category keywords the domain ranks for in SERP. The "include_subcategories" parameter allows you to manage the grouping of results, depending on your goals.

If "include_subcategories": false, the output will be grouped by separate groups of categories relevant to the content of the site. You will get the list of superordinate categories, where all keywords belong to any of the subcategories in the group. This grouping type is used to determine the most popular general domain category.

Consider the example:

[
  {
    "target": "apple.com",
    "language_code": "en",
    "location_name": "United States",
    "include_subcategories": false,
    "limit": 3
  }
]

{
  "version": "0.1.20221214",
  "status_code": 20000,
  "status_message": "Ok.",
  "time": "0.7710 sec.",
  "cost": 0.0103,
  "tasks_count": 1,
  "tasks_error": 0,
  "tasks": [
    {
      "id": "04052141-4426-0402-0000-05cd9da0ddf6",
      "status_code": 20000,
      "status_message": "Ok.",
      "time": "0.6707 sec.",
      "cost": 0.0103,
      "result_count": 1,
      "path": [
        "v3",
        "dataforseo_labs",
        "google",
        "categories_for_domain",
        "live"
      ],
      "data": {
        "api": "dataforseo_labs",
        "function": "categories_for_domain",
        "se_type": "google",
        "target": "apple.com",
        "language_code": "en",
        "location_name": "United States",
        "include_subcategories": false,
        "limit": 3
      },
      "result": [
        {
          "se_type": "google",
          "target": "apple.com",
          "location_code": 2840,
          "language_code": "en",
          "total_count": 3198,
          "items_count": 3,
          "items": [
            {
              "se_type": "google",
              "categories": [
                10013
              ],
              "metrics": {
                "organic": {
                  "pos_1": 51540,
                  "pos_2_3": 149057,
                  "pos_4_10": 889078,
                  "pos_11_20": 1158746,
                  "pos_21_30": 866202,
                  "pos_31_40": 669518,
                  "pos_41_50": 527450,
                  "pos_51_60": 412980,
                  "pos_61_70": 326321,
                  "pos_71_80": 259166,
                  "pos_81_90": 206779,
                  "pos_91_100": 120200,
                  "etv": 98834621.81085409,
                  "impressions_etv": 4518516.634428106,
                  "count": 5637048,
                  "estimated_paid_traffic_cost": 320188058.24251974,
                  "is_new": 2139485,
                  "is_up": 1413300,
                  "is_down": 1664274,
                  "is_lost": 0
                },
                "paid": {
                  "pos_1": 243,
                  "pos_2_3": 7,
                  "pos_4_10": 2,
                  "pos_11_20": 0,
                  "pos_21_30": 0,
                  "pos_31_40": 0,
                  "pos_41_50": 0,
                  "pos_51_60": 0,
                  "pos_61_70": 0,
                  "pos_71_80": 0,
                  "pos_81_90": 0,
                  "pos_91_100": 0,
                  "etv": 11170.279006451368,
                  "impressions_etv": 1503.922554910183,
                  "count": 252,
                  "estimated_paid_traffic_cost": 48360.593260228634,
                  "is_new": 247,
                  "is_up": 0,
                  "is_down": 2,
                  "is_lost": 0
                },
                "featured_snippet": null,
                "local_pack": null
              }
            },
            {
              "se_type": "google",
              "categories": [
                10019
              ],
              "metrics": {
                "organic": {
                  "pos_1": 242834,
                  "pos_2_3": 181953,
                  "pos_4_10": 355406,
                  "pos_11_20": 398325,
                  "pos_21_30": 311439,
                  "pos_31_40": 259429,
                  "pos_41_50": 222455,
                  "pos_51_60": 193647,
                  "pos_61_70": 171999,
                  "pos_71_80": 154405,
                  "pos_81_90": 138519,
                  "pos_91_100": 88041,
                  "etv": 272499801.15912527,
                  "impressions_etv": 15510038.236923676,
                  "count": 2718461,
                  "estimated_paid_traffic_cost": 705533091.7200391,
                  "is_new": 967423,
                  "is_up": 643463,
                  "is_down": 738077,
                  "is_lost": 0
                },
                "paid": {
                  "pos_1": 1243,
                  "pos_2_3": 68,
                  "pos_4_10": 5,
                  "pos_11_20": 0,
                  "pos_21_30": 0,
                  "pos_31_40": 0,
                  "pos_41_50": 0,
                  "pos_51_60": 0,
                  "pos_61_70": 0,
                  "pos_71_80": 0,
                  "pos_81_90": 0,
                  "pos_91_100": 0,
                  "etv": 1238342.8910437524,
                  "impressions_etv": 331307.9364384264,
                  "count": 1316,
                  "estimated_paid_traffic_cost": 3199428.891394019,
                  "is_new": 1223,
                  "is_up": 23,
                  "is_down": 19,
                  "is_lost": 0
                },
                "featured_snippet": null,
                "local_pack": null
              }
            },
            {
              "se_type": "google",
              "categories": [
                10108
              ],
              "metrics": {
                "organic": {
                  "pos_1": 42833,
                  "pos_2_3": 97467,
                  "pos_4_10": 381011,
                  "pos_11_20": 471524,
                  "pos_21_30": 362075,
                  "pos_31_40": 290740,
                  "pos_41_50": 237000,
                  "pos_51_60": 198300,
                  "pos_61_70": 164408,
                  "pos_71_80": 137978,
                  "pos_81_90": 115672,
                  "pos_91_100": 70626,
                  "etv": 198437350.5931524,
                  "impressions_etv": 3951472.2844962487,
                  "count": 2569637,
                  "estimated_paid_traffic_cost": 424726911.35021913,
                  "is_new": 976349,
                  "is_up": 627829,
                  "is_down": 752681,
                  "is_lost": 0
                },
                "paid": {
                  "pos_1": 252,
                  "pos_2_3": 5,
                  "pos_4_10": 0,
                  "pos_11_20": 0,
                  "pos_21_30": 0,
                  "pos_31_40": 0,
                  "pos_41_50": 0,
                  "pos_51_60": 0,
                  "pos_61_70": 0,
                  "pos_71_80": 0,
                  "pos_81_90": 0,
                  "pos_91_100": 0,
                  "etv": 11466.362834751606,
                  "impressions_etv": 434.12948656082153,
                  "count": 257,
                  "estimated_paid_traffic_cost": 30230.939217984676,
                  "is_new": 252,
                  "is_up": 0,
                  "is_down": 3,
                  "is_lost": 0
                },
                "featured_snippet": null,
                "local_pack": null
              }
            }
          ]
        }
      ]
    }
  ]
}

If "include_subcategories": true, the output will be grouped according to specific categories. That means that the biggest number of keywords belongs to the superordinate category and its subcategories at the same time. This method is used to compare specific categories for particular search queries.

Consider the example:

[
  {
    "target": "apple.com",
    "language_code": "en",
    "location_name": "United States",
    "include_subcategories": true,
    "limit": 3
  }
]

{
  "version": "0.1.20221214",
  "status_code": 20000,
  "status_message": "Ok.",
  "time": "2.6299 sec.",
  "cost": 0.0103,
  "tasks_count": 1,
  "tasks_error": 0,
  "tasks": [
    {
      "id": "04051819-4426-0402-0000-894bd41d8826",
      "status_code": 20000,
      "status_message": "Ok.",
      "time": "2.5387 sec.",
      "cost": 0.0103,
      "result_count": 1,
      "path": [
        "v3",
        "dataforseo_labs",
        "google",
        "categories_for_domain",
        "live"
      ],
      "data": {
        "api": "dataforseo_labs",
        "function": "categories_for_domain",
        "se_type": "google",
        "target": "apple.com",
        "language_code": "en",
        "location_name": "United States",
        "include_subcategories": true,
        "limit": 3
      },
      "result": [
        {
          "se_type": "google",
          "target": "apple.com",
          "location_code": 2840,
          "language_code": "en",
          "total_count": 1247372,
          "items_count": 3,
          "items": [
            {
              "se_type": "google",
              "categories": [
                10108,
                13691
              ],
              "metrics": {
                "organic": {
                  "pos_1": 3981,
                  "pos_2_3": 14197,
                  "pos_4_10": 55836,
                  "pos_11_20": 55079,
                  "pos_21_30": 37574,
                  "pos_31_40": 28036,
                  "pos_41_50": 21815,
                  "pos_51_60": 17113,
                  "pos_61_70": 13419,
                  "pos_71_80": 10721,
                  "pos_81_90": 8197,
                  "pos_91_100": 4582,
                  "etv": 20313557.51025193,
                  "impressions_etv": 421187.5262326347,
                  "count": 270550,
                  "estimated_paid_traffic_cost": 107375554.56345287,
                  "is_new": 92222,
                  "is_up": 70471,
                  "is_down": 81078,
                  "is_lost": 0
                },
                "paid": {
                  "pos_1": 14,
                  "pos_2_3": 1,
                  "pos_4_10": 0,
                  "pos_11_20": 0,
                  "pos_21_30": 0,
                  "pos_31_40": 0,
                  "pos_41_50": 0,
                  "pos_51_60": 0,
                  "pos_61_70": 0,
                  "pos_71_80": 0,
                  "pos_81_90": 0,
                  "pos_91_100": 0,
                  "etv": 408.60299521684647,
                  "impressions_etv": 0,
                  "count": 15,
                  "estimated_paid_traffic_cost": 1120.5281476974487,
                  "is_new": 14,
                  "is_up": 0,
                  "is_down": 1,
                  "is_lost": 0
                },
                "featured_snippet": null,
                "local_pack": null
              }
            },
            {
              "se_type": "google",
              "categories": [
                10013,
                10109,
                13546
              ],
              "metrics": {
                "organic": {
                  "pos_1": 1049,
                  "pos_2_3": 4207,
                  "pos_4_10": 30333,
                  "pos_11_20": 39917,
                  "pos_21_30": 28708,
                  "pos_31_40": 23005,
                  "pos_41_50": 18546,
                  "pos_51_60": 14948,
                  "pos_61_70": 12236,
                  "pos_71_80": 9930,
                  "pos_81_90": 8025,
                  "pos_91_100": 4567,
                  "etv": 2642854.5255384147,
                  "impressions_etv": 67615.42327669542,
                  "count": 195473,
                  "estimated_paid_traffic_cost": 3957612.9988049003,
                  "is_new": 75961,
                  "is_up": 48533,
                  "is_down": 57875,
                  "is_lost": 0
                },
                "paid": {
                  "pos_1": 3,
                  "pos_2_3": 0,
                  "pos_4_10": 0,
                  "pos_11_20": 0,
                  "pos_21_30": 0,
                  "pos_31_40": 0,
                  "pos_41_50": 0,
                  "pos_51_60": 0,
                  "pos_61_70": 0,
                  "pos_71_80": 0,
                  "pos_81_90": 0,
                  "pos_91_100": 0,
                  "etv": 88.16399812698364,
                  "impressions_etv": 0,
                  "count": 3,
                  "estimated_paid_traffic_cost": 527.56201171875,
                  "is_new": 2,
                  "is_up": 0,
                  "is_down": 0,
                  "is_lost": 0
                },
                "featured_snippet": null,
                "local_pack": null
              }
            },
            {
              "se_type": "google",
              "categories": [
                10019,
                10167
              ],
              "metrics": {
                "organic": {
                  "pos_1": 14716,
                  "pos_2_3": 16588,
                  "pos_4_10": 28968,
                  "pos_11_20": 29677,
                  "pos_21_30": 21437,
                  "pos_31_40": 17081,
                  "pos_41_50": 14086,
                  "pos_51_60": 11637,
                  "pos_61_70": 9771,
                  "pos_71_80": 8334,
                  "pos_81_90": 6943,
                  "pos_91_100": 4047,
                  "etv": 4829229.8653119095,
                  "impressions_etv": 371813.3430768503,
                  "count": 183286,
                  "estimated_paid_traffic_cost": 14628927.494498773,
                  "is_new": 64043,
                  "is_up": 42923,
                  "is_down": 49598,
                  "is_lost": 0
                },
                "paid": {
                  "pos_1": 23,
                  "pos_2_3": 1,
                  "pos_4_10": 0,
                  "pos_11_20": 0,
                  "pos_21_30": 0,
                  "pos_31_40": 0,
                  "pos_41_50": 0,
                  "pos_51_60": 0,
                  "pos_61_70": 0,
                  "pos_71_80": 0,
                  "pos_81_90": 0,
                  "pos_91_100": 0,
                  "etv": 476.7270088195801,
                  "impressions_etv": 11.852280378341675,
                  "count": 24,
                  "estimated_paid_traffic_cost": 3817.263705790043,
                  "is_new": 23,
                  "is_up": 0,
                  "is_down": 0,
                  "is_lost": 0
                },
                "featured_snippet": null,
                "local_pack": null
              }
            }
          ]
        }
      ]
    }
  ]
}

Exit mobile version