Server 1709 And above : https://learn.microsoft.com/en-us/iis/configuration/system.applicationhost/sites/site/hsts
Below :
Enter the following values in the Add Custom HTTP Response Headers dialog box:<Name: Strict-Transport-Security Value: max-age=31536000
Close the IIS Manager after confirmation.