When setting up services in Active Directory Domain Services (AD DS), administrators must choose the right type of service account to keep the system secure and easy to manage. The main goal is to follow least-privilege principles, which means giving each service only the permissions it truly needs. This choice becomes especially important in hybrid environments that span both on-premises servers and Azure services.
Three main types of service accounts exist in Windows Server environments:
Each type serves different scenarios, and the choice depends on where the service runs, how many servers it uses, and what security features the organization needs.
gMSAs work best when services run across multiple servers, such as in a server farm or behind a network load balancer. These accounts provide a single identity that all servers can use, which simplifies management significantly.
Key benefits include:
Choose gMSAs when your service needs to run on more than one server or when you want to reduce the manual work of password updates.
sMSAs serve services that run on a single server. They offer the same automatic password management and security benefits as gMSAs but cannot be shared across multiple machines.
Key characteristics:
Use sMSAs when your service runs on a single server and you want the security benefits of managed passwords without the complexity of gMSAs.
Sometimes neither gMSAs nor sMSAs fit the situation. In those cases, administrators fall back to user accounts, which come in two forms:
Considerations for user accounts:
When deciding which account type to use, ask these questions:
A decision tree that branches based on the number of servers, application support for managed accounts, and network access requirements to choose between gMSA, sMSA, and domain or local user accounts.
Managing service accounts well keeps the environment secure over time:
Choosing the right service account type balances security with operational needs. gMSAs and sMSAs reduce administrative work and improve security through automated password management, while domain user accounts provide flexibility when managed accounts won't work with certain applications.
Eager to master hybrid server management? Discover how to administer Windows Server Hybrid Core Infrastructure on Azure, setting your path towards the Microsoft Certified: Azure Hybrid Infrastructure Administrator Associate certification!
Prepare and test your skills

Prepare and test your skills

A Group Managed Service Account (gMSA) is a managed service account that works best when services run across multiple servers, such as in a server farm or behind a network load balancer. It provides automatic password management (the OS changes the password every 30 days), strong security with complex randomly generated passwords, and can be deployed across all servers in the farm. Use a gMSA when your service needs to run on more than one server or when you want to reduce the manual work of password updates.
A Standalone Managed Service Account (sMSA) serves services that run on a single server and offers the same automatic password management and security benefits as gMSAs but cannot be shared across multiple machines. Passwords change every 30 days automatically. Use an sMSA when your service runs on a single server and you want the security benefits of managed passwords without the complexity of gMSAs.
The main difference is scope: gMSAs can be used by multiple servers in a server farm or load-balanced environment, while sMSAs are limited to a single server. Both provide automatic password management that changes passwords every 30 days and use complex randomly generated passwords. Choose gMSAs for multi-server services and sMSAs for single-server services.
Use a domain user account when the service requires network access or when managed service accounts are not supported by the application. Domain user accounts exist in AD DS and can access resources across the network, supporting Kerberos authentication. However, password management becomes manual with domain user accounts, so administrators must track and update passwords on schedule.