Best Ide for Python

Looking for best ide for python? Python by itself is not an IDE. But, there are options to get an IDE experience working with the language.

What is an IDE?

An IDE (Integrated Development Environment) is a software application used by developers for creating programs. IDEs are meant to make the developer’s job easier by combining tools that are necessary during software development. Your typical IDE will contain tools such as:

  • a text editor;
  • a compiler and/or interpreter;
  • a debugger and code profiler;
  • version control integration;
  • a number of supporting utilities to interface with external tooling (Docker, cloud deployments, etc.)

…all combined into a single user interface.

Many IDEs also include additional, optional features and toolkits. Some are single-language-specific, others support every language you can think of, either out of the box or through plugins.

One thing is certain: the selection is so wide that you will definitely find an IDE that can cover all your needs.

IDE vs. code editor

An IDE is a complex tool that will have your back during the entire process of software development. However, for smaller projects—or those people who would value customization above everything else—a code editor might be enough.

A code editor doesn’t have the word “integrated” in the name for a reason; it’s just an editor, with additional features like syntax highlighting and code formatting.

But code editors do have their advantages. They are more lightweight, and the more advanced editors allow you to customize your software development experience with handpicked plugins and tools. They tend to be favored by those who value customizability and don’t mind a little tweaking before they find their bliss.

Some code editors are so complex and offer so many extensions that they can easily replace an IDE.

The best Python IDEs and code editors

The list we’ve assembled is based on the opinions of Python developers at STX Next (and there are over 200 of them!), as well as the popularity index according to the Stack Overflow Developer Survey and the State of Developer Ecosystem by Jetbrains. Note that the data from the Stack Overflow Survey concern the developers working with all the programming languages, while the Jetbrains and STX Next ones have only considered the opinions of Pythonistas.

Popularity of environments and tools among Python developers - PyCharm, VS Code, Sublime Text, Vim, Atom, Supyter, Notepad++
Popularity of environments and tools among Python developers

As far as Python developers are concerned, PyCharm wins the popularity contest, with Visual Studio Code being the runner-up. But since IDEs and editors are highly specialized, these two may not fit your individual needs.

To help you make the difficult choice between the multiple editors, we prepared a detailed list of options, focusing on the cross-platform ones.

1. PyCharm
PyCharm interface window
Source: https://www.jetbrains.com/pycharm/

Free or paid: PyCharm has a free community edition, but its full, professional version is paid. A free trial is available. For students, there is PyCharm Educational Edition.

System compatibility: Windows, macOS, Linux

Description and features: Developed by JetBrains, PyCharm is a comprehensive, Python-specific IDE.

PyCharm combines all the Python tools in one place. It offers:

  • an intelligent code editor,
  • navigation and refactoring tools,
  • a debugger,
  • a test runner.

It also allows code inspections and supports VCS. PyCharm’s code inspection is one of the most advanced among all Python IDEs, making it much harder to introduce preventable bugs through static and runtime code analysis.

The paid version additionally offers:

  • a Python profiler;
  • remote development;
  • database tools;
  • assistance in web development (by supporting frameworks like Pyramid, Flask or Django, as well as JavaScript, CoffeeScript, TypeScript, HTML/CSS, AngularJS, Node.js, and more);
  • scientific tools (it integrates with IPython Notebook and supports packages like Matplotlib and NumPy).

Use it if: you’re looking for a comprehensive Python development tool that will not only make you more efficient, but also boost the quality of your code. Especially if you’re in the fields of ML/AI, data science, or web development!

2. Visual Studio Code
Visual Studio Code interface window
Source: https://code.visualstudio.com/

Free or paid: Visual Studio Code is free to download and open source with freeware binaries.

System compatibility: Windows, macOS, Linux

Description and features: Visual Studio Code is a complete code editor developed by Microsoft. While it has many premium features and is customizable, it has a clear and easy UX, and installing new extensions is beyond easy.

Visual Studio Code provides:

  • syntax highlighting,
  • bracket-matching,
  • auto-indentation,
  • box-selection,
  • built-in support for IntelliSense code completion,
  • rich semantic code understanding and navigation,
  • code refactoring tools,
  • a debugger. 

It integrates with build and scripting tools and supports Git.

Visual Studio Code is known for its innovative features, like Live Share, which allows you to do real pair-programming remotely. Its unique architecture also made it possible for Microsoft to create a cloud-based service out of it, allowing you to leverage VS Code features wherever you are.

Visual Studio Code is extensible and customizable, letting you add more features and connect to additional services (one such extension is a Python package).

Use it if: you want a light, fast editor with an easy interface and customization options. VSC features some one-of-a-kind features like the Live Share mentioned above, which you might find useful!

3. Sublime Text
Sublime Text interface window with code

Free or paid: Sublime Text is shareware (may be downloaded and evaluated for free, but a license must be purchased for continued use).

System compatibility: Windows, macOS, Linux

Description and features: Sublime Text is a lightweight, cross-platform code editor, known for being simple to use, fast, and easily customizable.

Sublime Text offers:

  • split editing,
  • syntax highlighting,
  • auto-completion,
  • command palette,
  • “Goto” options meant to maximize your efficiency, like:
    • Goto Anything (“open files with only a few keystrokes, and instantly jump to symbols, lines or words”),
    • Goto Definition (which allows the editor to “automatically generate a project-wide index of every class, method and function”).

Sublime Text has a powerful Python API that guarantees easy customization with tools and packages (after getting the Package Control manager). 

Use it if: you’re a non-beginner looking for a beautiful, high-performing, customizable editor that is lightweight at the same time.

4. Vim
Vim interface window with code

Free or paid: Vim is completely free and open source.

System compatibility: macOS, Windows, Linux

Description and featuresVim is an extensible terminal-based editor.

Vim is all about configurability and, as its official website states, “it will not hold your hand.” While its entry threshold is not the lowest, your preparations will pay off. Vim is fast, effective, and 100% suited to your needs.

At its very core, Vim is a text editor equipped with all the basic features to facilitate writing code. It:

  • highlights syntax,
  • points out errors,
  • looks for syntax matches,
  • offers code completion,
  • and more!

Vim is known for its simple commands, but to use this feature effectively, you have to “start Insert mode to enter text and return to Normal mode to execute commands.” This “split” model might take some time to get used to. But in the end, it makes your work faster, as you can keep both your hands on the keyboard!

The reason why Vim is so popular among Python developers is the fact that it’s highly customizable. It offers a plethora of different extensions and plugins.

Use it if: you are an experienced developer and you know what you want—or you have time to read quite a lot of guides. If your preferred way of working doesn’t include a mouse, or you do a lot of work on a remote server, Vim is the way to go.

5. Atom
Atom interface window with code

Free or paid: Atom is free and open source.

System compatibility: Windows, macOS, Linux

Description and features: Atom is an open-source text editor known for its simple interface and wide customizability. It is available to download on a dedicated GitHub and welcomes user-made content.

Atom self-advertises as hackable. It even features packages of IDE-like features for a more comprehensive experience.

The text editor itself offers:

  • smart auto-completion,
  • multiple panes,
  • a built-in package manager,
  • a file system browser,
  • a find-and-replace feature,
  • an ability to work with Git and Github directly from Atom,
  • an ability to share your workspace with others in real-time.

The greatest strength of Atom is the variety of packages, which can make the editor fit your needs perfectly. It offers a lot of themes and it’s easy to customize and style it. So, you can create a Python-friendly environment for yourself, enriched with whatever features you need.

Use it if: you want an open-source, fast, and customizable editor without sacrificing the aesthetics.

Read or download as PDF
6. Jupyter Notebook
Jupyter Notebook interface window with code
Source: https://jupyter.org/

Free or paid: Jupyter Notebook is free and open source.

System compatibility: Windows, macOS, Linux, and cloud-hosted instances

Description and featuresJupyter Notebook is an open-source web app that supports multiple programming languages.

Jupyter Notebook allows creating and sharing documents that contain live code, equations, visualizations, and narrative text. Its uses include:

  • data cleaning and transformation,
  • numerical simulation,
  • statistical modeling,
  • data visualization,
  • machine learning,
  • and more.

There are a number of Jupyter-like platforms that you can access through the web browser without any setup on your machine. These include Azure Notebooks, Google Colab, or Watson Studio Cloud.

Fun fact: some of our articles even started out as Jupyter Notebook files!

Use it if: you work in the fields of machine learning and data science, or just want a quick tool that’s always on hand for small data-crunching scripts.

7. Eclipse + PyDev + LiClipse
PyDev interface window with code
Source: https://www.pydev.org/screenshots.html

Free or paid: EclipsePyDev and LiClipse are free and open-source.

System compatibility: Windows, macOS, Linux

Description and features: Developed by the Eclipse Foundation, the Eclipse IDE is one of the most notable ones out there. While primarily used for Java, it is perfect for Python development when combined with PyDev. It is strongly recommended that users also install LiClipse for optimal performance.

PyDev can be used in Python, Jython, and IronPython development. It includes code editor, navigation and refactoring tools, as well as a debugger.

It also offers an interactive console and tools for code completion, code analysis, and code coverage.

With LiClipse, PyDev supports other programming and templating languages, like Django Templates, Mako, RST, C++, CoffeeScript, Dart, HTML, JavaScript, CSS, and more.

Use it if: you’re looking for an open-source, full-fledged IDE that will help improve the quality of your code, no matter the programming language used.

8. GNU Emacs
GNU Emacs interface window with code

Free or paid: GNU Emacs is completely free and open source. 

System compatibility: Windows, macOS, Linux

Description and features: Emacs is described as “the extensible, customizable, self-documenting real-time display editor.” It was developed by the GNU project founder, Richard Stallman.

GNU Emacs offers content-aware editing modes, including syntax coloring, for many file types. It has built-in documentation, full Unicode support, and a whole array of functionalities beyond text editing available through packages. One such package is elpy, which can easily turn your editor into an IDE equivalent.

Like Vim, Emacs was created with the terminal—and mouse-free operation—in mind, but it also has a graphical interface for those that want to get a more modern UI experience.

The Emacs guide promises that “all of the basic editing commands (and there are lots of them) are available no matter what you’re trying to do,” and so are “all the tools Emacs provides for opening, saving, searching and processing text.” This means that you don’t have to switch to other software while using Emacs.

It also has a clear packaging system for downloading and installing extensions.

Bonus: you can play Tetris in Emacs.

You can play Tetris in Emacs
Source: https://www.gnu.org/software/emacs/tour/

Use it if: you value minimalism, but you also want your editor to be highly extensible and allow you the freedom of choice.

9. Spyder
Spyder interface window with code
Source: https://www.spyder-ide.org/

Free or paid: Spyder is free and open source.

System compatibility: Windows, macOS, Linux

Description and features: Spyder is an IDE developed by and for the people in the scientific fields. It is available through Anaconda.

It includes:

  • an editor (with syntax highlighting, introspection, code completion, real-time analysis, and more);
  • a debugger;
  • a profiler;
  • a variable explorer;
  • an IPython console;
  • static code analysis;
  • file explorer;
  • history log;
  • a lot of other features that make for a comprehensive IDE.

What makes it suited for the scientific fields, though, is its built-in integration with many popular scientific packages, including NumPy, SciPy, Pandas, IPython, QtConsole, matplotlib, SymPy, and more. It is also heavily customizable thanks to third-party plugins, and can be used as a PyQt5 extension library.

Use it if: you’re in the field of machine learning or data science and you’re looking for a comprehensive tool to speed up your work and save you some time looking for libraries and tools on your own.

10. Thonny
Thonny interface window with code
Source: https://thonny.org/

Free or paid: Thonny is free and open source

System compatibility: Windows, macOS, Linux

Description and features: Thonny deserves a special mention on this list, as it’s an IDE meant for Python beginners, created with an educational purpose. It was developed by the University of Tartu, Estonia, with special help from the RaspberryPi foundation and Cybernetica AS.

Thonny has Python 3.7 already built-in, so one installation is all you need to get started. Its entire interface is clear and easy to navigate. In the code editor, the syntax errors are highlighted, and the debugger is exceptionally simple. You can also try out code completion. In addition, it works great with MicroPython.

When it comes to the educational aspects, Thonny allows you to see how your programs and shell commands affect Python variables, and how Python evaluates your expressions. You can access a new window with a separate local variables table and code pointer, as well as have your scopes and references explained.

Use it if: you’re a new Pythonista and want to have additional insights into the basics of Python operation while you code.

Requirements for a Good Python Coding Environment

So what things do we really need in a coding environment? Feature lists vary from app to app, but there are a core set of features that makes coding easier:

  • Save and reload code files
    If an IDE or editor won’t let you save your work and reopen everything later, in the same state it was in when you left, it’s not much of an IDE.
  • Run code from within the environment
    Similarly, if you have to drop out of the editor to run your Python code, then it’s not much more than a simple text editor.
  • Debugging support
    Being able to step through your code as it runs is a core feature of all IDEs and most good code editors.
  • Syntax highlighting
    Being able to quickly spot keywords, variables, and symbols in your code makes reading and understanding code much easier.
  • Automatic code formatting
    Any editor or IDE worth it’s salt will recognize the colon at the end of a while or for statement, and know the next line should be indented.

Of course, there are lots of other features you might want, like source code control, an extension model, build and test tools, language help, and so on. But the above list is what I’d see as “core features” that a good editing environment should support.

With these features in mind, let’s take a look at some general purpose tools we can use for Python development.

General Editors and IDEs with Python Support

Eclipse + PyDev

Category: IDE
Website: www.eclipse.org
Python tools: PyDev, www.pydev.org

If you’ve spent any amount of time in the open-source community, you’ve heard about Eclipse. Available for Linux, Windows, and OS X at, Eclipse is the de-facto open-source IDE for Java development. It has a rich marketplace of extensions and add-ons, which makes Eclipse useful for a wide range of development activities.

One such extension is PyDev, which enables Python debugging, code completion, and an interactive Python console. Installing PyDev into Eclipse is easy: from Eclipse, select Help, Eclipse Marketplace, then search for PyDev. Click Install and restart Eclipse if necessary.

Eclipse with PyDev installed

Pros: If you’ve already got Eclipse installed, adding PyDev will be quicker and easier. PyDev is very accessible for the experienced Eclipse developer.

Cons: If you’re just starting out with Python, or with software development in general, Eclipse can be a lot to handle. Remember when I said IDEs are larger and require more knowledge to use properly? Eclipse is all that and a bag of (micro)chips.

Sublime Text

Category: Code Editor
Website: http://www.sublimetext.com

Written by a Google engineer with a dream for a better text editor, Sublime Text is an extremely popular code editor. Supported on all platforms, Sublime Text has built-in support for Python code editing and a rich set of extensions (called packages) that extend the syntax and editing features.

Installing additional Python packages can be tricky: all Sublime Text packages are written in Python itself, and installing community packages often requires you to execute Python scripts directly in Sublime Text.

Sublime Text code editor

Pros: Sublime Text has a great following in the community. As a code editor, alone, Sublime Text is fast, small, and well supported.

Cons: Sublime Text is not free, although you can use the evaluation version for an indefinite period of time. Installing extensions can be tricky, and there’s no direct support for executing or debugging code from within the editor.

To make the most of your Sublime Text setup, read our Python + Sublime Text setup guide and consider our in-depth video course that shows you how to craft an effective Python development setup with Sublime Text 3.

 Remove ads

Atom

Category: Code Editor
Website: https://atom.io/

Available on all platforms, Atom is billed as the “hackable text editor for the 21st Century.” With a sleek interface, file system browser, and marketplace for extensions, open-source Atom is built using Electron, a framework for creating desktop applications using JavaScript, HTML, and CSS. Python language support is provided by an extension that can be installed when Atom is running.

Atom code editor

Pros: It has broad support on all platforms, thanks to Electron. Atom is small, so it downloads and loads fast.

Cons: Build and debugging support aren’t built-in but are community provided add-ons. Because Atom is built on Electron, it’s always running in a JavaScript process and not as a native application.

GNU Emacs

Category: Code Editor
Website: https://www.gnu.org/software/emacs/

Back before the iPhone vs Android war, before the Linux vs Windows war, even before the PC vs Mac war, there was the Editor War, with GNU Emacs as one of the combatants. Billed as “the extensible, customizable, self-documenting, real-time display editor,” GNU Emacs has been around almost as long as UNIX and has a fervent following.

Always free and available on every platform (in one form or another), GNU Emacs uses a form of the powerful Lisp programming language for customization, and various customization scripts exist for Python development.

GNU Emacs editor

Pros: You know Emacs, you use Emacs, you love Emacs. Lisp is a second language, and you know the power it gives you means you can do anything.

Cons: Customization means writing (or copy/pasting) Lisp code into various script files. If it’s not already provided, you may have to learn Lisp to figure out how to do it.

Plus, you know that Emacs would be a great operating system, if it only had a good text editor…

Be sure to consult our Python + Emacs setup guide to make the most of this setup.

Vi / Vim

Category: Code Editor
Website: https://www.vim.org/

On the other side of the Text Editor War stands VI (aka VIM). Included by default on almost every UNIX system and Mac OS X, VI has an equally fervent following.

VI and VIM are modal editors, separating the viewing of a file from the editing of a file. VIM includes many improvements on the original VI, including an extensibility model and in-place code building. VIMScripts are available for various Python development tasks.

VIM text editor

Pros: You know VI, you use VI, you love VI. VIMScripts don’t scare you, and you know you bend it to your will.

Cons: Like Emacs, you’re not comfortable finding or writing your own scripts to enable Python development, and you’re not sure how a modal editor is supposed to work.

Plus, you know that VI would be a great text editor, if only it had a decent operating system.

If you’re going with this combination, check out our Python + VIM setup guide with tips and plugin recommendations.

 Remove ads

Visual Studio

Category: IDE
Website: https://www.visualstudio.com/vs/
Python tools: Python Tools for Visual Studio, aka PTVS

Built by Microsoft, Visual Studio is a full-featured IDE, in many ways comparable to Eclipse. Built for Windows and Mac OS only, VS comes in both free (Community) and paid (Professional and Enterprise) versions. Visual Studio enables development for a variety of platforms and comes with its own marketplace for extensions.

Python Tools for Visual Studio (aka PTVS) enables Python coding in Visual Studio, as well as Intellisense for Python, debugging, and other tools.

Pros: If you already have Visual Studio installed for other development activities, adding PTVS is quicker and easier.

Cons: Visual Studio is a big download for just Python. Plus, if you’re on Linux, you’re out of luck: there’s no Visual Studio install for that platform.

Visual Studio Code

Category: Code Editor
Website: https://code.visualstudio.com/
Python tools: https://marketplace.visualstudio.com/items?itemName=ms-python.python

Not to be confused with full Visual Studio, Visual Studio Code (aka VS Code) is a full-featured code editor available for Linux, Mac OS X, and Windows platforms. Small and light-weight, but full-featured, VS Code is open-sourceextensible, and configurable for almost any task. Like Atom, VS Code is built on Electron, so it has the same advantages and disadvantages that brings.

Installing Python support in VS Code is very accessible: the Marketplace is a quick button click away. Search for Python, click Install, and restart if necessary. VS Code will recognize your Python installation and libraries automatically.

Visual Studio Code editor

Pros: Thanks to Electron, VS Code is available on every platform, surprisingly full-featured despite having a small footprint, and open-source.

Cons: Electron means VS Code is not a native app. Plus, some people may have principled reasons to not use Microsoft resources.

Be sure to consult our tutorial on using Visual Studio Code for Python development, as well as the companion video course, to make the most of this setup.

Python-Specific Editors and IDEs

PyCharm

Category: IDE
Website: https://www.jetbrains.com/pycharm/

One of the best (and only) full-featured, dedicated IDEs for Python is PyCharm. Available in both paid (Professional) and free open-source (Community) editions, PyCharm installs quickly and easily on Windows, Mac OS X, and Linux platforms.

Out of the box, PyCharm supports Python development directly. You can just open a new file and start writing code. You can run and debug Python directly inside PyCharm, and it has support for source control and projects.

PyCharm IDE for Python

Pros: It’s the de facto Python IDE environment, with tons of support and a supportive community. It edits, runs, and debugs Python out of the box.

Cons: PyCharm can be slow to load, and the default settings may need tweaking for existing projects.

 Remove ads

Spyder

Category: IDE
Website: https://github.com/spyder-ide/spyder

Spyder is an open-source Python IDE that’s optimized for data science workflows. Spyder comes included with the Anaconda package manager distribution, so depending on your setup you may already have it installed on your machine.

What’s interesting about Spyder is that it’s target audience is data scientists using Python. You’ll notice this throughout. For example, Spyder integrates well with common Python data science libraries like SciPyNumPy, and Matplotlib.

Spyder features most of the “common IDE features” you might expect, such as a code editor with robust syntax highlighting, Python code completion, and even an integrated documentation browser.

A special feature that I haven’t seen in other Python editing environments is Spyder’s “variable explorer” that allows you to display data using a table-based layout right inside your IDE. Personally, I usually don’t have a need for this but it does look neat. If you regularly do data science work using Python, you might fall in love with this unique feature. The IPython/Jupyter integration is nice as well.

Overall, I’d say that Spyder feels more basic than other IDEs. I like to view it more as a special purpose tool rather than something I use as my primary editing environment every day. What is nice about this Python IDE is that it is available for free on Windows, macOS, and Linux and that it is fully open-source software.

Spyder Python IDE Screenshot

Pros: You’re a data scientist using the Anaconda Python distribution.

Cons: More experienced Python developers might find Spyder too basic to work with on a daily basis and instead opt for a more complete IDE or customized editor solution.

Thonny

Category: IDE
Website: http://thonny.org/

A recent addition to the Python IDE family, Thonny is billed as an IDE for beginners. Written and maintained by the Institute of Computer Science at the University of Tartu in Estonia, Thonny is available for all major platforms, with installation instructions on the site.

By default, Thonny installs with its own bundled version of Python, so you don’t need to install anything else new. More experienced users may need to tweak this setting so already installed libraries are found and used.

Thonny IDE for beginners

Pros: You’re a beginning Python user, and want an IDE that’s ready to roll.

Cons: More experienced Python developers will find Thonny too basic for most uses, and the built-in interpreter is something to work around, not with. Plus, as a new tool, there may be issues you find which may not have immediate solutions.

If you’re interested in using Thonny as your Python editor, be sure to read our dedicated article on Thonny which goes into more depth and shows you additional features.

Which Python IDE is Right for You?

Only you can decide that, but here are some basic recommendations:

New Python developers should try solutions with as few customizations as possible. The less gets in the way, the better.

If you use text editors for other tasks (like web pages or documentation), look for code editor solutions.

If you’re already developing other software, you may find it easier to add Python capabilities to your existing toolset.

Conclusion

Python is an awesome language. It has some pretty awesome frameworks designed to help you get up and running with minimal hassle. Now, this doesn’t mean that you should drop Django and go for Flask straightaway. There are a lot of great frameworks built on top of Django that help streamline your development process.

Leave a Comment