Error while uploading JSON file for ITR Return

4728 views 1 replies

I have prepared income tax return u/s 139(8A) using excel utility on Income Tax portal. After that I have generated json file. The JSON file is saved by default with some path. Now when I am uploading the json file on income tax portal, it is giving error message as under:

 

SyntaxError:Unexpected token'<',"<!DOCTYPE"...is not valid JSON.

 

Please guide on how to handle this issue.

 

Replies (1)

The error message you’re encountering, “SyntaxError: Unexpected token ‘<’ in JSON at position 0”, indicates that the content you’re trying to parse as JSON is not actually valid JSON. Let’s troubleshoot this issue step by step:

  1. Check the Content Format:

    • Ensure that the content you’re uploading is indeed in JSON format and not HTML or XML. Sometimes, if the server returns an HTML page (such as an error page) instead of valid JSON, you’ll encounter this error.
    • Verify that the file you generated from the Excel utility is correctly saved in JSON format.
  2. Missing or Extra Commas:

    • Check for any missing or extra commas in your JSON file. Commas are essential to separate different elements within the JSON structure.
    • Make sure that each key-value pair is separated by a comma, except for the last one.
  3. Use Double Quotes and Escape Special Characters:

    • JSON requires double quotes around keys and string values. Ensure that all keys and string values are enclosed in double quotes.
    • If your JSON contains special characters (such as backslashes or quotes), make sure to escape them properly. For example:
      {
        "name": "John Doe",
        "address": "123 Main St, \"City\"",
        "descripttion": "This is a \"test\" descripttion."
      }
      
  4. Check for Mismatched Brackets or Quotes:

    • Make sure that all opening brackets ({ and [) have corresponding closing brackets (} and ]).
    • Verify that all quotes are properly matched (i.e., every opening quote has a corresponding closing quote).
  5. Validate Your JSON:

    • Use a tool like JSONLint to validate your JSON. Paste your JSON content into the tool, and it will highlight any errors or issues.
    • Fix any reported errors and ensure that your JSON is well-formed.

Remember that the error message you’re seeing occurs when the parser encounters unexpected characters (such as <) while trying to interpret the content as JSON. By following the steps above, you should be able to identify and resolve the issue with your JSON file. If you need further assistance, feel free to ask! 😊

 

Leave a Reply

Your are not logged in . Please login to post replies

Click here to Login / Register  

Company
ARTICLESHIP 24 June 2026
CA Article Trainee

Rahul Dang & Associates

Pune

CA Inter

View Details
Company
24 June 2026
Chartered Accountant - GST & Direct Tax

APL

Mumbai

CA

View Details
Company
Featured 15 June 2026
Senior Auditor

N. Dhawan & Co

New Delhi

CA Inter

View Details
Company
25 June 2026
Accounts & Taxation Executive

Dindukurthy & Associates

Hyderabad

MBA

View Details
Company
ARTICLESHIP 04 June 2026
Article

Rakhecha & Co.

New Delhi

CA Inter

View Details
Company
ARTICLESHIP 09 June 2026
Article Trainee

Numbertree LLP

Mumbai

CA Inter

View Details
Company
09 June 2026
Accounts Associate

S Madan and CO

New Delhi

Graduate (Any)

View Details
Company
19 June 2026
Accounts Executive

Getfive Advisors Pvt. Ltd.

Ahmedabad

CA Inter

View Details