https://www.markhamstra.com/modx/2012/07/3-tips-for-serving-a-modx-site-over-ssl/
This question has been answered by michelle84. See the first response.
# Redirect all "not correct" domain to www with https
# (is not important if comes with or without https):
RewriteCond %{HTTP_HOST} !^www\.mysite\.com$ [NC]
RewriteRule ^(.*)$ https://www.mysite.com/$1 [L,R=301]
# Redirect all non-ssl to ssl
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://www.mysite.com/$1 [R,L]RewriteCond %{HTTP_HOST} .
RewriteCond %{HTTP_HOST} !^www\.nmldesign\.nl [NC]
RewriteRule (.*) http://www.nmldesign.nl/$1 [R=301,L]