What’s the best Python language server for Cursor? I can’t even get self or cls highlighted properly

I recently switched to Cursor from PyCharm, and honestly — reading Python code here is painful.

I tried multiple color themes and fonts, but eventually realized the problem isn’t in the theme — it’s in the language server itself.

I can’t get proper semantic highlighting:

  • self and cls are not highlighted at all,

  • function arguments look exactly the same as local variables,

  • overall the code feels flat and hard to read.

I’ve tried almost everything:

  • Tried enabling Pylance, but it seems unavailable in Cursor (only via VSIX or workarounds).

  • Installed the Cursor Pyright fork — no effect.

  • Switched between “None” and “Pylance” in settings — nothing changed.

  • Also tested BasedPyright and Pyright, but couldn’t get meaningful highlighting.

At this point, I’m not sure if I’m even moving in the right direction.

Could someone please explain:

  1. Which language server actually provides proper semantic highlighting for Python in Cursor (like in PyCharm or VS Code with Pylance)?

  2. How to configure it correctly so that self, cls, and function arguments have distinct colors?

Any working setup or settings.json examples would be greatly appreciated :folded_hands:

BasedPyright, which is the default for the Cursor Python extension provides semantic tokens. There are probably subtle differences in Pylance and BasedPyright implementation which would lead to different colors for some symbols. You might try different options in the “Color Theme” setting to see if one resembles token colors from VSCode/PyCharm.

If you really want to get specific, you could ask your favorite LLM to output a custom workbench.colorCustomizations json blob that you can drop into your settings file, but I personally wouldn’t do that because there are so many different settings to override and you’ll risk conflicting colors.

Pyrefly (disclaimer, the project my team works on) implements semantic tokens and we are tweaking the different color output so you can leave us feedback if there is a specific symbol where you think the color is wrong. Here is an example issue: Semantic highlighting improvements · Issue #873 · facebook/pyrefly · GitHub. Comparison of Pylance/PyCharm vs Pyrefly help us a lot to understand the exact token, along with your Workbench Color Theme selection.