The Sundarban
Printed Mar 1, 2026, 7:00 AM EST
Yadullah Abidi is a Pc Science graduate from the University of Delhi and holds a postgraduate level in Journalism from the Asian College of Journalism, Chennai. With over a decade of expertise in Windows and Linux systems, programming, PC hardware, cybersecurity, malware analysis, and gaming, he combines deep technical information with stable editorial instincts.
Yadullah at indicate writes for MakeUseOf as a Staff Author, covering cybersecurity, gaming, and consumer tech. He formerly worked as Associate Editor at Candid.Abilities and as News Editor at The Mac Observer, where he reported on everything from raging cyberattacks to the latest in Apple tech.
In addition to his journalism work, Yadullah is a stout-stack developer with expertise in JavaScript/TypeScript, Subsequent.js, the MERN stack, Python, C/C++, and AI/ML. Whether he’s analyzing malware, reviewing hardware, or building tools on GitHub, he brings a hands-on, developer’s standpoint to tech journalism.
For these who heard Python was coming to Excel and conception it was another thing you needed to learn to code, I’ve got moral information. Certain, Python in Excel is a highly efficient way of cleaning up and organizing your data, nevertheless you don’t need to be a programmer to use it at all.
Moral love using basic VBA scripting in Excel makes it distinguished better, knowing a few Python commands and how to use them can elevate your Excel expertise. I’ve spent years watching Excel users fight with data that appears to be like to be love it was entered by 5 various individuals with 5 various ideas about formatting. And honestly, Python in Excel is one in every of essentially the most beginner-pleasant alternatives for tackling these headaches.
Getting started is easier than you think
Microsoft hid the hardest parts and left you with the useful ones

For these who have a Microsoft 365 subscription (Business or Enterprise), you already have access to Python in Excel. No installation, no setup, no downloading mysterious packages from the internet.
To activate it, legal click the Formulas tab and decide out Insert Python. Even extra efficient? Kind =PY into any cell and press Tab. That’s it. You can be now in Python mode. There is now not any separate window, no black terminal display, no intimidating command prompts. Or no longer it is legal Excel, nevertheless with Python superpowers.
Although there may be a range of Python capabilities and syntax in Excel, you don’t need to memorize any Python code. Microsoft has integrated Copilot with Python in Excel. You can literally kind any tasks you want in plain English, love “remove duplicates from this list” or “fill missing sales values with the average,” and Copilot writes the Python code for you. Right here’s a great way of learning Python in Excel, as you can inspect the code and alter it as needed.
Using Python in Excel
Python handles messy data that would take dozens of formulas
In the occasion you opt out your data in Excel and use the xl() function, Python creates something called a DataFrame. Think of it as Excel creating a orderly-smart table that is aware of how to clean itself.
Let’s say you have a customer list with 500 rows, and you believe you studied there are duplicates. In traditional Excel, you’d have to use the Take away Duplicates option in the Data menu, decide out columns, and hope for the best.
With Python in Excel, you opt out your data range and kind two lines:
df = xl(“A1:D500”, headers=Legal)
df.drop_duplicates()

That’s it. The first line tells Python to assign the chosen data to a variable called df. The 2d line eliminates all duplicates automatically. What makes this approach better is no longer the fact that it really works with legal two lines of code—it is that you can inspect exactly what’s happening. No hidden checkboxes or mysterious settings to deal with.
The same theory applies whereas you are dealing with missing data. Empty cells are the bane of every analyst’s existence. Generally you want to fill them with zeros, typically with averages, and typically you want to delete empty rows entirely.
Let’s say you want to fill missing values in a spreadsheet’s sales column with the median value. Moral escape the following line:
df[‘Sales’].fillna(df[‘Sales’].median(), inplace=Legal)

This single line finds all the empty cells in your sales column and fills them with the median value from that same column. Are attempting that with standard Excel formulas and you will finish up with a mess of helper columns before you realize it.
Another frequent example of Python’s helpfulness in Excel is textual divulge cleanup. Ever got a dataset where any person typed “USA”, “U.S.A”, “United States”, and “US” to mean the same thing? This inconsistency can break pivot tables, ruins charts, and makes analysis nearly very unlikely.
Python’s replace() function handles this elegantly:
df[‘Country’].replace([‘U.S.A.’, ‘United States’, ‘US’], ‘USA’, inplace=Legal)

This finds every variation and standardizes them to “USA”. You can handle dozens of replacements in seconds, something that would take extra than one Find & Replace operations in regular Excel.
You can enact this with dates as neatly. For these who may perhaps have got got an Excel spreadsheet with dates entered in every imaginable format, you can standardize everything in seconds with a single line of code:
df[‘Date’] = pd.to_datetime(df[‘Date’])

Python’s pandas library, which comes built-in with Python in Excel, automatically recognizes most date formats and converts them to a standard format. Once again, it may take extra than one Find & Replace operations and a ton of time to fix this otherwise.
Another function I really love in Python for Excel is describe(). It provides you an instant statistical summary of your total dataset.
df.describe()

This single command returns the count, mean, standard deviation, minimum, maximum, and quartiles for every numeric column in your data. Or no longer it is love having Excel’s Analysis ToolPak condensed into one command, making it incredibly easy to hastily space outliers in your data.



