# Exporting user\_metadata or app\_metadata are empty

**URL:** <https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954>\
**Category:** Get Help\
**Tags:** user-import-export, user-management\
**Created:** [May 20, 2025, 11:01am UTC](https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954 "2025-05-20T11:01:13Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![antonio.acuna](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/antonio.acuna/32/72177_2.png) [@antonio.acuna](https://community.auth0.com/u/antonio.acuna)\
**Post date:** [May 20, 2025, 11:01am UTC](https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954/1 "2025-05-20T11:01:13Z")

</div>

Hello! I’m trying to export my users, including a few fields that are inside `app_metadata` and `user_metadata`, but the downloaded CSV doesn’t include them.

When I look into my users → raw JSON to verify the info is there, I can clearly see the `user_metadata.groups` being an array of strings.

This is an example, but I couldn’t make it work with any of the fields inside `app_metadata` or `user_metadata`.

Thanks!

---

<div class="post-metadata">

**Author:** ![dawid.matuszczyk](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dawid.matuszczyk/32/74550_2.png) [@dawid.matuszczyk](https://community.auth0.com/u/dawid.matuszczyk)\
**Post date:** [May 20, 2025, 12:33pm UTC](https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954/3 "2025-05-20T12:33:29Z")

</div>

Hi @antonio.acuna

Welcome to the Auth0 Community!

Thank you for posting your question. If you are exporting users in the CSV format you have to provide the full path to the object for the export:

```auto
{
//rest of user profile...
"app_metadata": {
   "address": {
      "street_address": {
          "number": "1",
      }
   }
}

```

To get the number attribute value exported the field would need to be specified like below:

```auto
{
"connection_id": "<connection ID here",
"format": "csv",
"fields": [
{
"name": "user_id"
},
{
"name": "username"
},
{
"name": "app_metadata.address.street_address.number"
}
]
}

```

Alternatively, you can use the JSON object instead of the CSV to export the entire object or the list by just requesting the app\_metadata/user\_metadata.

You can read more about that here → [Fields that can be Exported using the Bulk Export Tool](https://community.auth0.com/t/fields-that-can-be-exported-using-the-bulk-export-tool/118891)

Thanks  
Dawid

---

<div class="post-metadata">

**Author:** ![antonio.acuna](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/antonio.acuna/32/72177_2.png) [@antonio.acuna](https://community.auth0.com/u/antonio.acuna)\
**Post date:** [May 20, 2025, 1:18pm UTC](https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954/4 "2025-05-20T13:18:07Z")

</div>

Hello @dawid.matuszczyk , I’m using the User Import / Export extension.

And yes, I’m using the full path. In my case is:

```auto
{
// raw JSON from user
"user_metadata": {
        "groups": [
            "group_1",
            "group_2",
            "group_3"
        ]
    },
}

```

And in the Export tool, I use:

User Attribute → Field Name  
`email` → Email  
`identities[0].connection` → Connection  
`last_login` → Last Login  
`user_metadata.groups` → Groups

---

<div class="post-metadata">

**Author:** ![dawid.matuszczyk](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dawid.matuszczyk/32/74550_2.png) [@dawid.matuszczyk](https://community.auth0.com/u/dawid.matuszczyk)\
**Post date:** [May 20, 2025, 1:28pm UTC](https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954/5 "2025-05-20T13:28:45Z")

</div>

Thank you for the reply, @antonio.acuna. Can you try to export the users with the `POST /API/v2/jobs/users-exports`? [https://auth0.com/docs/manage-users/user-migration/bulk-user-exports](https://auth0.com/docs/manage-users/user-migration/bulk-user-exports). I want to identify if that’s an issue on the extension side or maybe a misconfiguration.

Thanks  
Dawid

---

<div class="post-metadata">

**Author:** ![antonio.acuna](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/antonio.acuna/32/72177_2.png) [@antonio.acuna](https://community.auth0.com/u/antonio.acuna)\
**Post date:** [May 21, 2025, 4:02pm UTC](https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954/6 "2025-05-21T16:02:39Z")

</div>

Hello again @dawid.matuszczyk

I tried with the API using:

`--data '{"connection_id": "con_5Ub8BzBuwK24SpbB", "format": "csv", "limit": 5, "fields": [{"name": "email"}, { "name": "identities[0].connection", "export_as": "provider" }, { "name": "last_login" }, { "name": "user_metadata.groups"}, { "name": "groups"}]}'`

But both user\_metadata.groups and groups where empty but if you access an index of the array it works:

`--data '{"connection_id": "con_5Ub8BzBuwK24SpbB", "format": "csv", "limit": 5, "fields": [{"name": "email"}, { "name": "identities[0].connection", "export_as": "provider" }, { "name": "last_login" }, { "name": "user_metadata.groups[0]"}, { "name": "groups[0]"}]}'`

Obviously, it’s not the expected behaviour but probably a hint to understand the issue. Also, the json version fill the fields correctly using both versions so this array issue is something that only happens with CSV exports.

---

<div class="post-metadata">

**Author:** ![dawid.matuszczyk](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dawid.matuszczyk/32/74550_2.png) [@dawid.matuszczyk](https://community.auth0.com/u/dawid.matuszczyk)\
**Post date:** [May 22, 2025, 11:33am UTC](https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954/7 "2025-05-22T11:33:24Z")

</div>

Hi @antonio.acuna

Thank you for the reply. For the confirmation, if you access the index of the array, does the export return the whole array or only the value from the first index?

I will talk with the team internally to better understand the behaviour behind the CSV export.

Thanks  
Dawid

---

<div class="post-metadata">

**Author:** ![antonio.acuna](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/antonio.acuna/32/72177_2.png) [@antonio.acuna](https://community.auth0.com/u/antonio.acuna)\
**Post date:** [May 23, 2025, 7:20am UTC](https://community.auth0.com/t/exporting-user-metadata-or-app-metadata-are-empty/186954/8 "2025-05-23T07:20:20Z")

</div>

Hi @dawid.matuszczyk using CSV export if I access the index of the array I get returned the value on that index, not the whole array. I didn’t try using JSON export.
