how to install tensorflow on anaconda python 3.6
Master System Design with Codemia
Enhance your system design skills with over 120 practice problems, detailed solutions, and hands-on exercises.
Introduction
Installing TensorFlow into an Anaconda environment built on Python 3.6 is now a legacy setup rather than a modern default. That distinction matters, because current TensorFlow installation guidance targets newer Python versions and recommends pip inside an isolated environment, so if you must stay on Python 3.6 you need to choose an older TensorFlow release that still published compatible wheels.
Understand the Compatibility Constraint First
The most important detail is compatibility, not the exact command. Current TensorFlow releases no longer target Python 3.6, so a fresh pip install tensorflow in a Python 3.6 environment will usually fail or select nothing usable.
The safe approach is:
- Create a dedicated conda environment with Python 3.6
- Activate it
- Install a TensorFlow version that still supported Python 3.6
- Verify the import immediately
In practice, this means treating the environment as a legacy project environment rather than a long-term default for new work.
Create the Conda Environment
Start by creating and activating a separate environment.
Keeping TensorFlow in its own environment avoids conflicts with newer projects and prevents accidental upgrades that break the setup.
Install TensorFlow with pip Inside the Conda Environment
Even when you use Anaconda for environment management, TensorFlow is commonly installed with pip inside that environment.
If your platform or project requires an earlier release, use the version your codebase expects instead. The key point is that the TensorFlow version must still have wheels built for Python 3.6.
After installation, verify it:
If TensorFlow imports and prints a version number, the basic installation succeeded.
Why Not conda install tensorflow?
Many developers expect conda to provide the cleanest installation path, but TensorFlow’s own guidance has favored pip packages for official releases. In a conda-managed environment, that usually means:
- Use conda to manage Python and system isolation
- Use
pipto install the TensorFlow wheel
That hybrid approach is normal and avoids confusion when conda channels lag behind the official package releases.
GPU Installs Need Extra Compatibility Checks
If you need GPU support in an old Python 3.6 environment, the setup becomes stricter. You must match:
- TensorFlow version
- CUDA version
- cuDNN version
- Operating system support
- Driver compatibility
For many legacy projects, CPU-only installation is simpler and more reproducible. If you do need GPU support, pin the exact versions used by the project rather than trying random combinations.
Verify the Installation with a Small Test
Do not stop after the package installs. Run a minimal TensorFlow operation to confirm the runtime is working.
If this prints the TensorFlow version and a numeric result, the environment is at least functional for basic use.
When You Should Upgrade Instead
If you are starting a new project, Python 3.6 is the wrong place to begin. Use a modern Python version and the current TensorFlow install path instead. Staying on Python 3.6 only makes sense when:
- You maintain an older production model
- A library dependency hard-requires the old stack
- You need reproducibility for historical experiments
In those cases, write the environment details down in a reproducible form such as environment.yml or requirements.txt.
Common Pitfalls
The most common mistake is trying to install the newest TensorFlow into Python 3.6. Current packages are built for newer Python versions, so this usually fails before you even get to runtime.
Another mistake is mixing too many package managers and channels at once. Create the conda environment, then install the TensorFlow wheel cleanly instead of layering multiple conflicting installations.
A third mistake is ignoring GPU compatibility tables. A package version may install successfully but still fail at runtime if its CUDA and cuDNN expectations are wrong.
Summary
- Python 3.6 plus TensorFlow is a legacy environment and must use an older compatible TensorFlow release.
- Use conda to create the environment, then install TensorFlow with
pipinside it. - Verify the installation with both
import tensorflowand a small tensor operation. - Prefer CPU-only installs unless you know the exact GPU dependency matrix.
- For new work, upgrade Python and use the current TensorFlow installation guidance instead.

