Requirement: Get SharePoint Farm ID to apply a third party product license to our SharePoint 2016 environment.
How to Get SharePoint Farm ID?
SharePoint farm id is a GUID which is uniquely identifies each farm. To get the Farm ID in SharePoint, use this handy PowerShell code.
Just open SharePoint 2016 Management Shell and paste this cmdlet in it to find the farm id of the SharePoint Farm. This gets you the SharePoint farm id:
You’ll get a GUID similar to the above screenshot. Although you can query the SharePoint Farm config database to get this information, it’s strongly recommended to use PowerShell, instead of accessing the SharePoint database.
To get the GUID of SharePoint Web Application, Site Collection, Site, List or Library, Fields, View – Refer: How to Find the GUIDs of SharePoint Web Application, Site Collection, Site, List, View and Columns