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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
eliasayyy
Memorable Member
Memorable Member

GA4 connector error

i keep getting this error in power query 

DataFormat.Error: We found an unexpected character in the JSON input.
Details:
Value=\31
Position=0

2 REPLIES 2
Shabyman2
Frequent Visitor

Hi,

We are experiencing the same issue, this is PBI Desktop > GA connector > Valid credentials.

Surely this is a Microsoft bug it needs to fix? How can i edit a JSON coming through your connector in GA4? Is this something we have to do in GA4? Or a code change within the advanced editor with powerbi desktop?

Anonymous
Not applicable

Hi @eliasayyy 

The error message you're encountering in Power Query, "DataFormat.Error: We found an unexpected character in the JSON input," typically occurs when the JSON data you're trying to import or process has a formatting issue. Here are some steps to troubleshoot and resolve this error:

  1. Check JSON Format: Ensure that the JSON file or string you're trying to load is correctly formatted. The error indicates that there's an unexpected character ( ‘\31’ in this case) at the very beginning of the JSON data (Position=0). This could be a hidden character, a typographical error, or a formatting issue.

  2. Remove Hidden Characters: Sometimes, JSON files can contain hidden or non-printable characters that aren't visible in standard text editors. You can use a JSON validator or a text editor that shows all characters, including non-printable ones, to check for and remove any such characters.

  3. Use a JSON Validator: Run your JSON data through a JSON validator tool. These tools can help identify formatting issues or syntax errors in JSON data. They're widely available online.

  4. Encoding Issues: The issue might be due to encoding problems. Ensure that your JSON file is saved with the correct encoding (usually UTF-8). If you're getting the JSON data from an external source, check the encoding and make sure it's compatible with Power Query.

  5. Check for Data Corruption: If the JSON data comes from a file, ensure that the file is not corrupted. Try reloading or regenerating the JSON file if possible.

 

 

 

Best Regards,

Jayleny

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.