xlrd.biffh.XLRDError: Excel xlsx file; not supported [duplicate] xlrd.biffh.XLRDError: Excel xlsx file; not supported [duplicate] python python

xlrd.biffh.XLRDError: Excel xlsx file; not supported [duplicate]


As noted in the release email, linked to from the release tweet and noted in large orange warning that appears on the front page of the documentation, and less orange, but still present, in the readme on the repository and the release on pypi:

xlrd has explicitly removed support for anything other than xls files.

In your case, the solution is to:

  • make sure you are on a recent version of Pandas, at least 1.0.1,and preferably the latest release. 1.2 will make hiseven clearer.
  • install openpyxl: https://openpyxl.readthedocs.io/en/stable/
  • change your Pandas code to be:
    df1 = pd.read_excel(     os.path.join(APP_PATH, "Data", "aug_latest.xlsm"),     engine='openpyxl',)


The previous version, xlrd 1.2.0, may appear to work, but it could also expose you to potential security vulnerabilities. With that warning out of the way, if you still want to give it a go, type the following command:

pip install xlrd==1.2.0