Last modified: Jun 23, 2025 By Alexander Williams

How to Uninstall Boto3 in Python

Boto3 is the AWS SDK for Python. It helps you manage AWS services. Sometimes, you may need to uninstall it. This guide will show you how.

Why Uninstall Boto3?

You might need to uninstall boto3 for several reasons. Maybe you want a clean install. Or you are switching to another SDK. Whatever the reason, it's easy.

Like uninstalling Firebase Admin SDK, removing boto3 is simple. Follow the steps below.

Check If Boto3 Is Installed

First, check if boto3 is installed. Use the pip show command. This will show boto3 details.

 
pip show boto3


Name: boto3
Version: 1.26.0
Summary: AWS SDK for Python
Location: /usr/local/lib/python3.9/site-packages

If boto3 is installed, you will see its details. If not, you will see a "not found" message.

Uninstall Boto3 Using Pip

To uninstall boto3, use the pip uninstall command. This removes the package.

 
pip uninstall boto3


Found existing installation: boto3 1.26.0
Uninstalling boto3-1.26.0:
  Would remove:
    /usr/local/lib/python3.9/site-packages/boto3-1.26.0.dist-info/*
    /usr/local/lib/python3.9/site-packages/boto3/*
Proceed (Y/n)? Y
  Successfully uninstalled boto3-1.26.0

Type Y and press Enter. This confirms the uninstall. Boto3 will be removed.

Verify Boto3 Is Uninstalled

After uninstalling, verify it's gone. Use the pip show command again.

 
pip show boto3


WARNING: Package(s) not found: boto3

This means boto3 is no longer installed. You can also check Python.

 
import boto3


ModuleNotFoundError: No module named 'boto3'

This error confirms boto3 is uninstalled. Just like uninstalling PyMongo, it's simple.

Uninstall Boto3 Dependencies

Boto3 has dependencies like botocore. You may want to remove them too. Use the same pip uninstall command.

 
pip uninstall botocore

Repeat for other dependencies. Check with pip show.

Clean Up Residual Files

Sometimes, files remain after uninstall. Check the site-packages directory. Remove any leftover boto3 files.

 
ls /usr/local/lib/python3.9/site-packages | grep boto3

If you see any files, delete them manually. Be careful not to remove other packages.

Reinstall Boto3 If Needed

If you need boto3 again, reinstall it. Use the pip install command.

 
pip install boto3

This will install the latest version. You can specify a version if needed.

Conclusion

Uninstalling boto3 is straightforward. Use pip uninstall and verify removal. Clean up any leftover files. Now you know how to remove boto3 cleanly.

For other SDKs, like uninstalling SQLAlchemy, the process is similar. Always verify the uninstall.