How to Supercharge PyCharm’s Code Insight with Pyrefly’s Rust-Powered Type Engine
Introduction
If you're working with large Python codebases in PyCharm 2026.1.2, you know that code insight features like type inference, auto-completion, and inline documentation can sometimes slow down. That’s where Pyrefly steps in — Meta’s next-gen Python type checker written in Rust. It replaces the older Pyre and delivers blazing-fast performance by handling all type-related intelligence via the Language Server Protocol (LSP).

This how-to guide walks you through enabling Pyrefly as an external type provider in PyCharm. By the end, you’ll have a supercharged IDE that processes code insight much faster — perfect for maintaining large-scale Python projects.
What You Need
- PyCharm 2026.1.2 (Professional or Community edition)
- A local Python interpreter configured for your project (Docker, WSL, SSH not yet supported)
- Internet connection (PyCharm will automatically download Pyrefly when needed)
- Basic familiarity with PyCharm’s interface
Step-by-Step Guide
Step 1: Locate the Type Widget
At the bottom of the PyCharm window, you’ll see a status bar. Look for the Type widget — it usually reads “Type: Built-in” or “Type: Pyrefly” if already set. This widget is your gateway to switching type engines. If you can’t find it, ensure the status bar is visible (View → Appearance → Status Bar).
Step 2: Click and Select Pyrefly
Click on the Type widget. A pop-up menu appears with available type providers. By default, the IDE uses the built-in type engine. Select “Pyrefly (external type provider)” from the list. If Pyrefly isn’t installed on your system yet, don’t worry — PyCharm will handle it automatically in the next step.
Step 3: Wait for Automatic Installation
After selecting Pyrefly, PyCharm starts downloading and installing the Rust-based language server in the background. You’ll see a progress indicator near the bottom-right corner. This usually takes just a few seconds, depending on your internet speed. No manual downloads or configuration files are required. Once it finishes, the Type widget updates to show the Pyrefly icon.
Step 4: Verify the Active Engine
Hover your mouse over the Type widget again. A tooltip now displays “Pyrefly” along with the version number (e.g., v0.1.2). You can also click the widget to see details. This confirms that Pyrefly is now handling all code intelligence features.

Step 5: Enjoy Enhanced Performance
Open any Python file in your project. You’ll immediately notice improvements in:
- Code completion — faster and more accurate suggestions
- Hover documentation — instant display of types, parameters, and docstrings
- Go to definition — snappier navigation
- Type diagnostics — real-time error checking with less delay
- Inlay hints — beautiful, non-intrusive type annotations
Because Pyrefly runs as an LSP server written in Rust, it offloads heavy analysis from the main IDE process, resulting in a much more responsive experience — especially on large codebases.
Tips for Using Pyrefly in PyCharm
- Stick to local interpreters. The current integration only supports local configurations. If you use Docker, WSL, SSH, or multi-module projects, you’ll need to wait for future updates (planned).
- Monitor the Type widget. If the IDE ever reverts to the built-in engine, a click is all it takes to switch back to Pyrefly.
- Check for updates. Pyrefly is actively developed. Periodically revisit the Type widget to see if a newer version is available — PyCharm will prompt you.
- Performance tweaks. For extremely large codebases, consider excluding certain directories from analysis via project settings to further reduce load.
- Fallback option. If you encounter any compatibility issues, you can always switch back to the built-in type engine — no permanent change is made.
- Share feedback. Since this is a relatively new integration (part of PyCharm 2026.1.2), your feedback helps the JetBrains team prioritize improvements.
By following these steps, you’ve successfully integrated Pyrefly’s LSP with PyCharm. Enjoy the speed boost and keep your Python code insight lightning-fast!
Related Discussions