@Xu Wang Thanks for reply! You may follow the steps mentioned in this blog to update the Nginx configuration file to redirect your users from azurewebsites.net & to your custom domain.
- Go to Azure Portal, open a new SSH session. (https://<your-site-name>.scm.azurewebsites.net/webssh/host)
- Update Nginx Default.conf - Server Block (Edit- file is under /etc/nginx/conf.d/default.conf)
- Update Nginx Default.conf - Location Block
- Save Changes
- Use command
nginx -s reload
to restart the Nginx Service & load the new configuration so that your redirects should be working as expected.
Hope this helps. Let us know.