Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
gaccardo
Advocate II
Advocate II

Importing a Theme can Corrupt the .pbix file

A word of caution when working with themes...  Make sure that you experiment with a copy of your .pbix file.  With a bit of copy/paste, I managed to include the following in my theme .json file.  After importing it, I could no longer create any visuals, edit/resize anything, or even click on visual elements without errors.  The solution was to rebuild the .pbix file from a previous version.

 

    "*": {
      "*": {
        "*": [{
            "fontColor": {
              "solid": {
                "color": "#000000"
              }
            },

            "background": [{
                "color": {
                  "solid": {
                    "color": "#333333"
                  }
                },
                "transparency": 0
              }
            ],
            "fontFamily": "Arial"
          }
        ]
      }
    },
3 REPLIES 3
v-frfei-msft
Community Support
Community Support

Hi @gaccardo,

 

Based on my test, I can reproduce your issuer here, and this issue is related to triple wildcard . It is recommended to update the theme file to be more specific with the visualStyles section, replacing one of the wildcards with a specific entity (visual type or formatting card name). Here I updates your code as below, then everything goes well.

 

"visualStyles":{
    "barChart": {
        "*": [{
            "background": [{
                "Color": {
                  "solid": {
                   "Color": "#333333"
                  }
                },
                "transparency": 0
              }
            ],
         "fontFamily": "Arial"
          }
        ]

We got response from PG:

As the Theme feature is in preview, and the triple wildcard is technically working as expected, there is no “fix” coming. We also identified a popular third-party Power BI Theme Generator website (non-Microsoft) and asked the owners to change their tool to avoid creating triple wildcards.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Hi @gaccardo,

 

Does that make sense? If so , kindly mark the answer as a solution to close the case, thanks in advance.

 

Regards,
Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

The solution is for Microsoft to properly validate inputs.  If the theme file isn't valid, then the import should fail with an appropriate error message.

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors