In order to create report folders, you must check the box "Enable access levels for sharing report and dashboard folders" in Classic setup (search Folder Sharing in setup).

Is there any way to enable this setting automatically via SFDX scratch org def, or via settings metadata with either SFDX or MDAPI? Trying to avoid manual steps when creating new scratch orgs.

1 Answer 1


It's controlled by one of the flags, AnalyticsSharingEnable, on the new OrgPreferenceSettings entity, which can be accessed through either the Metadata API or the SFDX scratch org definition. In the latter form, it's enabled in this way:

    "orgName": "David Company",
    "edition": "Enterprise",
    "settings" : {
        "orgPreferenceSettings": {
            "analyticsSharingEnable": true

I find it rather counterintuitive, but the config file is documented to expect camelCaseVersions of the settings flags on this Metadata API entity.

  • WARNING: The setting "analyticsSharingEnable" is no longer supported as of API version 47.0
    – Andy Ray
    Commented Jun 2, 2020 at 3:10

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .