title: Google is not indexing https
body: <p>I have used the http protocol for a long time. After years I implemented a domain certificate. Now I am trying to get the website with the https:// protocol indexed but Google still indexes the http protocol.</p>
  <p>I have tried several things. I enabled the 'Force SSL with https redirect' option in DirectAdmin.</p>
  <p>I changed my .htaccess so the browser redirects every option to the https protocol:</p>
  <pre><code>RewriteEngine on
  RewriteCond %{HTTP_HOST} ^[^.]+\.[^.]+$
  RewriteCond %{HTTPS}s ^on(s)|
  RewriteRule ^ http%1://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
  RedirectMatch permanent index.php/(.*) https://www.***.com/$1
  RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.(php|html) [NC]
  RewriteRule ^index\.php$ https://www.***.com/ [R=301,L]
  RewriteCond %{THE_REQUEST} ^GET\ /.*/index\.(php|html)\ HTTP
  RewriteRule (.*)index\.(php|html)$ /$1 [R=301,L]
  RewriteCond %{HTTP_HOST} ^domain\.com$ [OR]
  RewriteCond %{HTTP_HOST} ^www\.domain\.com$
  RewriteRule ^home\.html$ &quot;https\:\/\/www\.domain\.com\/&quot; [R=301,L]
  RewriteCond %{HTTP_HOST} ^domain\.com$ [OR]
  RewriteCond %{HTTP_HOST} ^www\.domain\.com$
  RewriteRule ^home$ &quot;https\:\/\/www\.domain\.com\/&quot; [R=301,L]
  </code></pre>
  <p>I have created a sitemap.xml that contains only the https:// protocol.</p>
  <p>In the Google Search Console I see that the website is indexed today and that the 'Google selected canonical URL' is still the http protocol.</p>
  <p>Does someone know what I need to do to fix this problem?</p>