Natural number sorting vs plain alphabetical - am I the only one who cares?

Dec 04, 2026 Last reply: 7 hours ago 3 Replies

First reply

Russ_Frost

From what you describe, this isn't an Onshape quirk at all. It's standard lexicographic sorting, meaning the system reads character by character, so '10' comes before '2' because '1' sorts before '2'. Tons of systems do this, Windows included, so I'd argue it's not a bug or a…

Read the full reply

Does anyone else get irked by how Onshape sorts things in the file manager? I was organizing some folders in what I called Test Folder, all numbered, sorted ascending by Name, and the order comes out as 1, 10, 11, 12, 2, 3. Not exactly what I'd call consecutive. There's even a little arrow next to the column header confirming it's a straight ascending sort, so it's not me doing somethig wrong.



What gets me is that I mentioned this to support years ago and brought it up again today. thier answer both times is that it's a low priority issue. Feels like a big oversight to me, but maybe I'm in the minority here. So honest question for the group. Do you folks prefer strict alphabetical sorting, where the computer just reads character by character, or would you rather it understood numbers and put 2 before 10? I can see arguments both ways. Maybe some people rely on the current behavior for their naming setups and changing it would mess things up. Curious where everyone lands on this, because I genuinely can't tell if I'm being picky or if this bugs everyone quietly.


From what you describe, this isn't an Onshape quirk at all. It's standard lexicographic sorting, meaning the system reads character by character, so '10' comes before '2' because '1' sorts before '2'. Tons of systems do this, Windows included, so I'd argue it's not a bug or a big oversight, just how string comparison works everywhere. I can see why the low priority answer from support didn't sit well with you, but honestly I think they'd say the same thing about any system that sorts this way.

The good news is there's a simple naming habit that fixes it completely: zero-pad your numbers. Name them 01, 02, 03 and so on, all the way up as far as you need, and they sort in true consecutive order under the same ascending sort you're already using. The extra digit forces the character-by-character comparison to line up with the numeric order you actually want.

I used to find this behavior annoying too, until I understood why it happens, and now padding numbers is just second nature when I set up a folder structure. It does change your names slightly, so if you rely on the current ones for something, that's a fair reason to pause. But for a fresh set of numbered folders like your test setup, padding from the start is the way I'd go.

Honestly, I think the low priority answer bothers me more than the sorting itself. You're right that character-by-character ordering is the default everywhere, and zero-padding works, but plenty of other tools let you pick. If a folder manager gave me a toggle between plain alphabetical and natural sorting, everyone could be happy. That's what I'd be asking support for, rather than asking them to change the default.

The way I work, versioned part names are everywhere. I end up with things like bracket-v1, bracket-v2 and so on, and when a design goes past nine versions the sequence reads like yours does. I've just trained myself to pad the numbers from the start, two digits minimum, because I know how the sort behaves. It's a habit, not a fix I love, but it means I never think about it again. Where I'd push back slightly on your framing is the idea that changing it wouldn't mess anyone up. Sorting order affects how a whole team reads a shared document list, so a silent change to it could reorder things under people mid-project. An opt-in setting avoids that entirely. So my vote is for Onshape adding the option, not replacing the behavior. Until then, padding your Test Folder names is the least painful path, even if it feels like working around something that should just work.

Zero-padding is the one habit I wish someone had told me about years earlier. I used numbered names for a set of storage bins and hit the exact same 1, 10, 11 ordering mess, and renaming everything after the fact was way more annoying than just starting with 01 in the first place. Now I decide how many digits I'll ever need before I name the first folder and stick to it. Out of curiosity, when you followed up with support today, did they give any hint it might change eventually, or was it just the same low priority line both times?

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required