This is my first post in a series called A Beginner’s Tour Through Operating Systems. I wanted to start with something simple but interesting:
Why do macOS and Linux come with Python, but Windows doesn’t?
It’s a small question, but the answer tells us a lot about how different operating systems are built and how they work behind the scenes.
If you’re new to programming or just curious about how your computer is set up, this post is for you. Let’s take a closer look.
If you’ve ever cracked open your terminal on macOS or Linux and typed python
, you might’ve been surprised to see it just works. But try the same thing on a fresh Windows install? Nope. You’re either redirected to the Microsoft Store or met with a confused error message.
Why? What makes Windows different? And what’s the deal with those weird old Python 2.7 versions still lurking around?
Let’s walk through this, step by step, and explore the history and design philosophy of the major operating systems — and how that affects the Python experience.
Operating Systems Have Personalities#
Think of operating systems like different cultures. Each has its own tools, traditions, and way of getting things done:
- Linux: The tinkerer’s paradise. Open-source, modular, and built by the community. Loves shell scripts and automation.
- macOS: Sleek but Unix-based under the hood. Has deep roots in BSD Unix, with a focus on user-friendliness and a sprinkle of open-source goodness.
- Windows: Business-first, powered by Microsoft’s ecosystem. Prioritizes compatibility, .NET, PowerShell, and GUI tools.
These personalities shape which programming languages they rely on. And that’s where Python enters the story.
Why Python Comes Preinstalled on macOS and Linux#
Because They Use It Themselves#
macOS and Linux don’t just include Python — they depend on it.
Many of the behind-the-scenes scripts that manage the system (like software updates, network settings, or install tools like apt
, yum
, or brew
) are written in Python.
To avoid breaking critical tools, these OSes ship with Python preinstalled, usually tucked away in the system directories.
Fun Fact: macOS used Python 2.7 up through macOS Catalina, even though Python 3 was released in 2008. Why? Because legacy scripts still needed the older version.
Why Windows Doesn’t Include Python by Default#
Because It Never Needed To#
Windows has always marched to the beat of its own drum. Instead of Unix-like scripting, it grew up with:
- CMD (Command Prompt) – simple batch scripting
- PowerShell – powerful task automation, designed for system admins
- .NET & C# – the backbone of many Windows apps
Since Windows never relied on Python internally, there was no need to bundle it with the OS. Python was considered a third-party, developer-focused tool — something you download only if you need it.
Starting with Windows 10 (2019), typing
python
in the terminal triggers a prompt to install it via the Microsoft Store. It’s a small but helpful shift toward accessibility.
Why macOS and Linux Often Ship with Old Python Versions#
Even if your Mac or Ubuntu install has Python, you might notice it’s… ancient. Like, Python 2.7 — which officially died in 2020!
Why do they still keep it?
Because system stability > having the latest and greatest.
Many scripts still expect Python 2 syntax. Changing everything over to Python 3 would be like trying to upgrade all the roads in a country overnight — it’s risky, expensive, and could break a lot of things.
So they leave the old version in place — but only for internal use. Developers are encouraged to install Python 3 themselves and keep system Python untouched.
What Should You Do?#
Here’s your quick-start advice if you’re coding on any platform:
Action | Why |
---|---|
Don’t use system Python | It’s old, managed by the OS, and fragile |
Install your own Python | Control your version, avoid system conflicts |
Use venv or virtualenv | Keep your project environments isolated |
Use a version manager like pyenv | Easy switching between versions |
TL;DR#
- macOS and Linux include Python because their system tools depend on it.
- Windows doesn’t because it uses PowerShell and .NET instead.
- Python 2.7 still lingers in older systems because of legacy scripts.
- As a developer, always install your own Python and use virtual environments to stay sane.
Bonus Thought: Operating Systems as Ecosystems#
Understanding why certain tools are bundled — or not — gives you a deeper sense of the engineering trade-offs behind OS design.
Next time you set up a devopement environment or help a friend install Python, you’ll know exactly why things work the way they do, and how we got here.
Want more stories like this about the hidden logic of tech? Let me know — we can dive into package managers, shells, or even why file paths are so weird across systems!