You apply it in the Default Domain Policy GPO. This will effectively enforce the configuration for all users in the domain (unless you also implement Fine Grained Password Policy). Details in https://activedirectorypro.com/how-to-configure-a-domain-password-policy/
For Entra ID, as per https://learn.microsoft.com/en-us/entra/identity/authentication/concept-sspr-policy
Password expiry duration (Maximum password age) Default value: 90 days. If the tenant was created after 2021, it has no default expiration value. You can check current policy with Get-MgDomain. The value is configurable by using the Update-MgDomain cmdlet from the Microsoft Graph module for PowerShell.|
If you already implement password writeback in Entra ID, then this is all that's required.
If the above response helps answer your question, remember to "Accept Answer" so that others in the community facing similar issues can easily find the solution. Your contribution is highly appreciated.
hth
Marcin