Given the file path:


The filename is "abc.txt", and extension is "txt".

What is the "industry standard", unambiguous name for the "abc" part?

For reference, in both java's older java.io and newer java.nio libraries, filename means "abc.txt", and there is no term (ie the library APIs don't support) for the "abc" part.

  • Microsoft used "FilenameWithoutExtension" as the term in the .NET framework. – Mike Nov 29 '16 at 20:14
  • The best term I've come across is "file name without extension". It doesn't exactly roll off the tongue though. – David Arno Nov 29 '16 at 20:15
  • filename = name + extension – user188153 Nov 29 '16 at 21:29
  • Would be nice if the unambigious name also worked for filenames.with.several.periods and .dotfiles. But I doubt you´ll even find a standard one for Windows only (the main platform that cares about extensions). – RemcoGerlich Nov 29 '16 at 21:55
  • 2
    I don't see the question as opinion-based. It is asking for a standard term. The answer is that there is none. People may provide their opinion of what the term should be, but it wouldn't be an answer to the question. – user36800 Oct 30 '20 at 20:20

I believe that's just called the "filename" as well, which makes thing fairly confusing:

Discussions of filenames are complicated by a lack of standardisation of the term. Sometimes "filename" is used to mean the entire name, such as the Windows name c:\directory\myfile.txt. Sometimes, it will be used to refer to the components, so the filename in this case would be myfile.txt. Sometimes, it is a reference that excludes an extension, so the filename would be just myfile. Such ambiguity is widespread and this article does not attempt to define any one meaning, and indeed may be using any of these meanings. Some systems will adopt their own standardised nomenclature like "path name", but these too are not standardised across systems.

If it's important, you'll have to make sure you clarify exactly what "filename" you're talking about.

  • 1
    You haven't answered the question. You've only offered reasons to support it being asked. – Bohemian Nov 29 '16 at 19:43
  • 5
    @Bohemian Actually, it confirms that this question is purely opinion-based. There is no standard term. What you're asking for just doesn't exist. – Thomas Owens Nov 29 '16 at 19:45
  • @Bohemian You are assuming the question has an answer. For my part, I call the pieces "filename" and "filename extension". So I actually agree with FirstLastName's answer. – Eric King Nov 29 '16 at 20:09
  • 3
    @ThomasOwens that's what I was afraid of :) I use "non-extension part of the filename", but surely someone somewhere must have named this thing. How about "file stem" – Bohemian Nov 29 '16 at 20:14
  • Actually some consider the path part of the file name. – candied_orange Nov 30 '16 at 0:36

Not the answer you're looking for? Browse other questions tagged or ask your own question.