Python: Fix ModuleNotFoundError - No module named pandas


ModuleNotFoundError- No module named pandas

If while executing a Python program you get an error "ModuleNotFoundError" and it says "No module named 'pandas', then the reason for this error is, in your program, you have made use of the pandas module, but the module is not available locally on your device or your project.

In such case you need to make use of the pip3 package installer for Python and get pandas installed.


Fix: ModuleNotFoundError pandas

  1. Open Terminal/Command Prompt.
  2. Run the below command.
    pip3 install pandas

    or,

    pip install pandas
  3. Again run your code and it should not have this error again.
installing Pandas Module using Pip3
-

Facing issues? Have Questions? Post them here! I am happy to answer!


Author: Rakesh
Author Info:

Rakesh is a seasoned developer with over 10 years of experience in web and app development, and a deep knowledge of operating systems. Author of insightful How-To articles for Code2care.

Follow him on: X

Copyright © Code2care 2023 | Privacy Policy | About Us | Contact Us | Sitemap