How to find the internal name of list or library columns

This post is a guide on how to find the internal name of columns within Microsoft lists or document libraries in SharePoint.


In this post:

Intro
Option 1: list/ library settings
Option 2: sort or group by the column
Option 3: REST API request
Option 4: Microsoft Graph Explorer

Intro

Columns in Microsoft Lists/ SharePoint lists & libraries have two main names – their display name that you can see within the list or library and their internal name. Sometimes you may be required to use a column’s internal name (for example: when creating column/list view formatting). There are several ways to do this, depending on the column so take a look below for more:

NOTE: In the examples below I will be focusing on lists, but the same applies for document libraries.

Option 1: list/ library settings

This is by far the easiest way to get the internal name of a column. All internal custom columns, plus several of the out-the-box column names within lists or libraries can be found by heading to list settings and clicking on the column itself:

  • Press the cog > list/ library settings
Press list settings from the cog menu.
  • Scroll down until you see columns > select the column
  • The Field= end part of the URL in the browser will show you the internal name of your column (Modified By in my example)
Editing the column will show you the internal name of the column from the Field= part at the end of the URL .

Option 2: sort or group by the column

Some out-the-box columns don’t appear within list settings, but you can still get their internal name by either grouping or sorting based on the particular column. For example, the file size column is an out-the-box column that isn’t you won’t find in list settings. If you add this column to your list/ library view and sort you can get access to the internal name:

  • Click on the drop-down and press show/ hide columns
  • Select the column you wish to add > tick it > press apply
  • Select the drop-down next to your newly added column > either sort by or group by depending on what is available
    • For sorted columns – look for the sortField part of the URL to get the internal name of your column
URL example to find the internal name of sorted columns
  • For grouped columns – look for the groupBy part of the URL to get the internal name of your column
URL example to find the internal name of grouped columns.

Option 3: REST API requests

SharePoint has a REST API service that allows you to perform CRUD operations by using REST HTTP requests. There is much more information about the SharePoint REST service here, but you can use GET requests via the browser to return information as per your requirements.

In our example, we want to return all the internal column names from a given list. To do this we simply need to send a REST request to SharePoint as follows:

https://[YOUR SITE].sharepoint.com/_api/Web/Lists(guid'[YOUR GUID]')/Fields

This will return a huge wall of text, but if you CTRL+F and search for the name of your column or use a code editor you will find the internal name and display name:

Option 4: Microsoft Graph

You can also use the MS Graph Explorer to do something similar to a REST API request. The graph explorer allows you to create a run requests via an easy to use interface that also shows you the results. In our example I ran the following GET request via graph explorer:

https://graph.microsoft.com/v1.0/sites/[YOUR TENANT].sharepoint.com/sites/[YOUR SITE]/lists/[YOUR LIST]/Columns
Entering the above request in Graph Explorer will return you all the internal column names in your list.

Which allowed me to look through the response preview to find my file size column’s internal name: