Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
WPB Cup
25 Million+
Websites using our plugins
16+
Years of WordPress experience
3000+
WordPress tutorials
by experts

Wie man WordPress richtig von HTTP auf HTTPS umstellt (Anleitung für Anfänger)

Hinweis der Redaktion: Wir erhalten eine Provision für Partnerlinks auf WPBeginner. Die Provisionen haben keinen Einfluss auf die Meinung oder Bewertung unserer Redakteure. Erfahre mehr über Redaktioneller Prozess.

Möchten Sie WordPress von HTTP auf HTTPS umstellen und ein SSL-Zertifikat auf Ihrer Website installieren?

Wir haben viele Anfragen zu diesem Thema erhalten, da Google bereits im Juli 2018 angekündigt hat, dass der Chrome-Browser alle Websites ohne SSL als unsicher kennzeichnen wird.

In diesem Artikel zeigen wir Ihnen, wie Sie WordPress ordnungsgemäß von HTTP auf HTTPs umstellen, indem Sie ein SSL-Zertifikat hinzufügen.

Moving WordPress from HTTP to HTTPS / SSL

Machen Sie sich keine Sorgen, wenn Sie keine Ahnung haben, was SSL oder HTTPS ist. Auch das werden wir Ihnen erklären.

Was ist HTTPS?

HTTPS oder Secure HTTP ist eine Verschlüsselungsmethode, die die Verbindung zwischen dem Browser des Benutzers und Ihrem Server sichert. Dadurch wird es für Hacker schwieriger, die Verbindung abzuhören.

Jeden Tag geben wir unsere persönlichen Daten an verschiedene Websites weiter, sei es beim Einkaufen oder beim einfachen Einloggen.

Um die Datenübertragung zu schützen, muss eine sichere Verbindung hergestellt werden.

Hier kommen SSL und HTTPS ins Spiel.

Jeder Website wird zur Identifizierung ein eindeutiges SSL-Zertifikat ausgestellt. Wenn ein Server vorgibt, HTTPS zu verwenden, und sein Zertifikat nicht übereinstimmt, warnen die meisten modernen Browser den Benutzer davor, sich mit der Website zu verbinden.

Connection not private error in Google Chrome

Jetzt werden Sie sich wahrscheinlich fragen, warum ich meine WordPress-Website von HTTP auf HTTPS umstellen muss, vor allem, wenn es sich um einen einfachen Blog oder eine kleine Unternehmenswebsite handelt, die keine Zahlungen entgegennimmt.

Warum brauchen Sie HTTPS und SSL?

Im Jahr 2018 kündigte Google einen Plan zur Verbesserung der allgemeinen Websicherheit an, indem es die Eigentümer von Websites ermutigte, von HTTP auf HTTPS umzusteigen. Als Teil dieses Plans würde der beliebte Chrome-Webbrowser alle Websites ohne SSL-Zertifikat als „nicht sicher“ kennzeichnen.

Connection not secure

Google sagte auch, dass Websites mit SSL auch Vorteile für die Suchmaschinenoptimierung haben und bessere Suchergebnisse erzielen als unsichere Websites. Seitdem haben viele Websites von HTTP auf HTTPS umgestellt.

Nach der Ankündigung begann Google mit der Einführung der Warnung „Nicht sicher“ in Chrome. Wenn jemand zum Beispiel eine HTTP-Website im Inkognito-Fenster besucht, wird sie als nicht sicher gekennzeichnet. Wenn jemand eine HTTP-Website im normalen Modus besucht und versucht, ein Kontaktformular oder ein anderes Formular auszufüllen, wird die Website als unsicher gekennzeichnet.

Wenn Ihre Leser und Kunden diesen Hinweis sehen, vermittelt er ihnen einen schlechten Eindruck von Ihrem Unternehmen.

Aus diesem Grund müssen alle Websites von HTTP auf HTTPS umstellen und sofort SSL installieren.

Ganz zu schweigen davon, dass Sie SSL benötigen, wenn Sie auf Ihrer eCommerce-Website Online-Zahlungen akzeptieren möchten.

Die meisten Zahlungsunternehmen wie Stripe, PayPal Pro, Authorize.net usw. verlangen eine sichere Verbindung, bevor sie Zahlungen akzeptieren.

Wir verwenden SSL für unsere Websites, einschließlich WPBeginner, OptinMonster, WPForms und MonsterInsights.

Anforderungen für die Verwendung von HTTPS/SSL auf einer WordPress-Website

Die Anforderungen für die Verwendung von SSL in WordPress sind nicht sehr hoch. Sie müssen lediglich ein SSL-Zertifikat erwerben, und vielleicht haben Sie es bereits kostenlos.

Die besten WordPress-Hosting-Unternehmen bieten kostenlose SSL-Zertifikate für alle ihre Nutzer an:

Weitere Einzelheiten finden Sie in unserem Leitfaden zum Erhalt eines kostenlosen SSL-Zertifikats für Ihre WordPress-Website.

Wenn Ihr Hosting-Unternehmen kein kostenloses SSL-Zertifikat anbietet, müssen Sie ein SSL-Zertifikat erwerben.

Wir empfehlen die Verwendung von Domain.com, da sie das beste SSL-Angebot sowohl für reguläre als auch für Wildcard-SSL-Zertifikate anbieten.

Mit dem Kauf eines SSL-Zertifikats erhalten Sie auch ein TrustLogo-Siegel für Ihre Website, und jedes SSL-Zertifikat wird mit einer Sicherheitsgarantie von mindestens 10.000 US-Dollar geliefert.

Sobald Sie ein SSL-Zertifikat erworben haben, müssen Sie Ihren Hosting-Anbieter bitten, es für Sie zu installieren.

Einrichten von WordPress zur Verwendung von SSL und HTTPs

Nachdem Sie ein SSL-Zertifikat für Ihren Domainnamen aktiviert haben, müssen Sie WordPress so einrichten, dass SSL- und HTTPs-Protokolle auf Ihrer Website verwendet werden.

Wir zeigen Ihnen zwei Methoden, und Sie können diejenige wählen, die Ihren Bedürfnissen am besten entspricht.

Video-Anleitung

Subscribe to WPBeginner

Wenn Sie eine schriftliche Anleitung bevorzugen, lesen Sie einfach weiter

Methode 1: Einrichten von SSL/HTTPS in WordPress mithilfe eines Plugins

Diese Methode ist einfacher und wird für Anfänger empfohlen.

Zunächst müssen Sie das Really Simple SSL-Plugin installieren und aktivieren. Weitere Einzelheiten finden Sie in unserer Schritt-für-Schritt-Anleitung zur Installation eines WordPress-Plugins.

Nach der Aktivierung müssen Sie die Seite Einstellungen “ SSL aufrufen. Das Plugin erkennt automatisch Ihr SSL-Zertifikat und richtet Ihre WordPress-Site für die Verwendung von HTTPs ein.

SSL enabled on a WordPress website

Das Plugin kümmert sich um alles, auch um die Fehler bei gemischten Inhalten. Hier ist, was das Plugin hinter den Kulissen tut:

  • SSL-Zertifikat prüfen
  • WordPress so einstellen, dass https in URLs verwendet wird
  • Umleitungen von HTTP zu HTTPs einrichten
  • Suchen Sie nach URLs in Ihrem Inhalt, die noch von unsicheren HTTP-Quellen geladen werden, und versuchen Sie, diese zu korrigieren.

Hinweis: Das Plugin versucht, Fehler bei gemischten Inhalten zu beheben, indem es eine Ausgabepufferungstechnik verwendet. Dies kann sich negativ auf die Leistung auswirken, da es Inhalte auf der Website ersetzt, während die Seite geladen wird. Diese Auswirkung ist nur beim Laden der ersten Seite zu sehen und sollte minimal sein, wenn Sie ein Caching-Plugin verwenden.

Das Plugin sagt zwar, dass Sie SSL beibehalten und das Plugin sicher deaktivieren können, aber das ist nicht zu 100 % wahr. Sie müssen das Plugin immer aktiv lassen, da die Deaktivierung des Plugins zu Fehlern bei gemischten Inhalten führt. Weitere Einzelheiten finden Sie in unserer Really Simple SSL-Bewertung.

Methode 2: Manuelles Einrichten von SSL/HTTPS in WordPress

Bei dieser Methode müssen Sie die Probleme manuell beheben und die WordPress-Dateien bearbeiten. Dies ist jedoch eine dauerhafte und leistungsoptimierte Lösung. Dies ist, was wir auf WPBeginner verwenden.

Wenn Sie diese Methode für schwierig halten, können Sie einen WordPress-Entwickler beauftragen oder stattdessen die erste Methode anwenden.

Im Rahmen dieser Methode müssen Sie möglicherweise das WordPress-Theme und die Code-Dateien bearbeiten. Wenn Sie dies noch nicht getan haben, lesen Sie unsere Anleitung zum Kopieren und Einfügen von Codeschnipseln in WordPress.

Zuerst müssen Sie die Seite Einstellungen “ Allgemein aufrufen. Hier müssen Sie Ihre WordPress- und Website-URL-Adressfelder aktualisieren, indem Sie http durch https ersetzen.

Update WordPress URLs

Vergessen Sie nicht, auf die Schaltfläche „Änderungen speichern“ zu klicken, um Ihre Einstellungen zu speichern.

Sobald die Einstellungen gespeichert sind, meldet WordPress Sie ab und Sie werden aufgefordert, sich erneut anzumelden.

Als Nächstes müssen Sie WordPress-Umleitungen von HTTP zu HTTPS einrichten, indem Sie den folgenden Code in Ihre .htaccess-Datei einfügen:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
</IfModule>

Wenn Sie einen NGINX-Server verwenden, müssen Sie den folgenden Code in Ihre Konfigurationsdatei einfügen, um von HTTP auf HTTPS umzuleiten:

server {
listen 80;
server_name example.com www.example.com;
return 301 https://example.com$request_uri;
}

Vergessen Sie nicht, example.com durch Ihren Domänennamen zu ersetzen.

Wenn Sie diese Schritte befolgen, vermeiden Sie die Fehlermeldung „WordPress HTTPS funktioniert nicht“, da WordPress nun Ihre gesamte Website über https lädt.

Wenn Sie SSL und HTTPS für Ihren WordPress-Administrationsbereich oder Ihre Anmeldeseiten erzwingen möchten, müssen Sie SSL in der Datei wp-config.php konfigurieren.

Fügen Sie den folgenden Code oberhalb der Zeile „That’s all, stop editing!“ in Ihre wp-config.php-Datei ein:

define('FORCE_SSL_ADMIN', true);

Diese Zeile ermöglicht es WordPress, SSL / HTTPs im WordPress-Administrationsbereich zu erzwingen. Sie funktioniert auch bei WordPress-Multisite-Netzwerken.

Sobald Sie dies getan haben, ist Ihre Website vollständig für die Verwendung von SSL/HTTPS eingerichtet, aber Sie werden immer noch Fehler bei gemischten Inhalten feststellen.

Diese Fehler werden durch Quellen (Bilder, Skripte oder Stylesheets) verursacht, die noch mit dem unsicheren HTTP-Protokoll in den URLs geladen werden. Wenn dies der Fall ist, können Sie in der Adressleiste Ihrer Website kein sicheres Vorhängeschloss-Symbol sehen.

Not secure

Viele moderne Browser blockieren automatisch unsichere Skripte und Ressourcen. Möglicherweise sehen Sie ein Vorhängeschloss-Symbol mit einem entsprechenden Hinweis in der Adressleiste Ihres Browsers.

Insecure content blocked

Mit dem Tool Inspect können Sie herausfinden, welche Inhalte über ein unsicheres Protokoll bereitgestellt werden. Der Fehler mit gemischten Inhalten wird in der Konsole als Warnung mit Details für jedes Element mit gemischten Inhalten angezeigt.

Mixed content errors displayed in browser console

Sie werden feststellen, dass die meisten URLs Bilder, iframes und Bildergalerien sind, während einige Skripte und Stylesheets sind, die von Ihren WordPress-Plugins und Themes geladen werden.

Reparieren von gemischten Inhalten in der WordPress-Datenbank

Bei den meisten falschen URLs handelt es sich um Bilder, Dateien, Einbettungen und andere Daten, die in Ihrer WordPress-Datenbank gespeichert sind. Lassen Sie uns diese zuerst beheben.

Alles, was Sie tun müssen, ist, alle Erwähnungen Ihrer alten Website-URL in der Datenbank zu finden, die mit http beginnen, und sie durch Ihre neue Website-URL zu ersetzen, die mit https beginnt.

Sie können dies ganz einfach tun, indem Sie das Better Search Replace-Plugin installieren und aktivieren. Weitere Details finden Sie in unserer Schritt-für-Schritt-Anleitung für die Installation eines WordPress-Plugins.

Nach der Aktivierung müssen Sie die Seite Tools “ Better Search Replace aufrufen. Unter dem Feld „Suchen“ müssen Sie Ihre Website-URL mit http hinzufügen. Danach fügen Sie Ihre Website-URL mit https unter dem Feld „Ersetzen“ hinzu.

Search and replace

Darunter sehen Sie alle Ihre WordPress-Datenbanktabellen. Sie müssen alle auswählen, um eine gründliche Prüfung durchzuführen.

Schließlich müssen Sie das Kontrollkästchen neben der Option „Als Trockenlauf ausführen?“ deaktivieren und dann auf die Schaltfläche „Suchen/Ersetzen ausführen“ klicken.

Das Plugin durchsucht nun Ihre WordPress-Datenbank nach URLs, die mit http beginnen, und ersetzt sie durch sichere https-URLs. Je nach Größe Ihrer WordPress-Datenbank kann dies eine Weile dauern.

Fehler bei gemischten Inhalten im WordPress-Theme beheben

Ein weiterer häufiger Grund für Fehler bei gemischten Inhalten ist Ihr WordPress-Theme. Jedes anständige WordPress-Theme, das den WordPress-Codierungsstandards entspricht, wird dieses Problem nicht verursachen.

Zunächst müssen Sie das Inspektionstool Ihres Browsers verwenden, um die Ressourcen zu finden und festzustellen, von wo sie geladen werden.

Using inspect tool to find mixed content error

Danach müssen Sie sie in Ihrem WordPress-Theme finden und durch https ersetzen. Dies wird für die meisten Anfänger etwas schwierig sein, da Sie nicht sehen können, welche Theme-Dateien diese URLs enthalten.

Behebung von Fehlern bei gemischten Inhalten, die durch Plugins verursacht werden

Einige Mixed-Content-Ressourcen werden von WordPress-Plugins geladen. Jedes WordPress-Plugin, das die WordPress-Codierungsstandards einhält, verursacht keine Mixed-Content-Fehler.

Wir raten davon ab, WordPress-Plugin-Dateien zu bearbeiten. Stattdessen müssen Sie sich an den Autor des Plugins wenden und ihn informieren. Wenn er nicht antwortet oder das Problem nicht beheben kann, müssen Sie eine geeignete Alternative finden.

Hinweis: Wenn aus irgendeinem Grund immer noch ein Fehler bei gemischten Inhalten auftritt, empfehlen wir, das Really Simple SSL-Plugin vorübergehend zu verwenden, damit Ihre Benutzer nicht beeinträchtigt werden, während Sie das Problem auf einer Staging-Website beheben oder einen Entwickler beauftragen.

Melden Sie Ihre HTTPS-Website bei Google Search Console an

Suchmaschinen wie Google betrachten https und http als zwei verschiedene Websites. Das bedeutet, dass Sie Google mitteilen müssen, dass Ihre Website umgezogen ist, um SEO-Probleme zu vermeiden.

Dazu müssen Sie nur in Ihr Google Search Console-Konto gehen und auf die Schaltfläche „Eigenschaft hinzufügen“ klicken.

Add property

Daraufhin wird ein Popup-Fenster angezeigt, in dem Sie die neue https-Adresse Ihrer Website eingeben müssen.

Es gibt zwei Methoden zur Überprüfung von Websites: Domänenname oder URL-Präfix. Wir empfehlen die Methode mit dem URL-Präfix, weil sie flexibler ist.

Add website URL in Google Search Console

Danach werden Sie von Google aufgefordert, die Eigentumsrechte an Ihrer Website zu bestätigen.

Es gibt mehrere Möglichkeiten, dies zu tun. Wählen Sie eine Methode aus, und Sie erhalten Anweisungen zur Überprüfung Ihrer Website. Wir empfehlen die Verwendung der HTML-Tag-Methode.

HTML tag method to verify your site

Sie sehen nun ein HTML-Code-Snippet, das Sie im Kopfbereich Ihrer WordPress-Website einfügen müssen.

Search Console-Verifizierungscode mit All in One SEO hinzufügen

Installieren und aktivieren Sie zunächst das All in One SEO for WordPress-Plugin. Weitere Einzelheiten finden Sie in unserer Anleitung zur Installation eines WordPress-Plugins.

Hinweis: Es gibt auch eine kostenlose Version von All in One SEO, die Sie ausprobieren können.

Gehen Sie nach der Aktivierung auf die Seite All in One SEO “ Allgemeine Einstellungen und klicken Sie auf Google Search Console.

Add Google Search Console verification code in All in One SEO

Darunter müssen Sie den Verifizierungscode hinzufügen, den Sie zuvor von der Google Search Console-Website kopiert haben.

Vergessen Sie nicht, auf die Schaltfläche Änderungen speichern zu klicken, um Ihre Einstellungen zu speichern.

Wechseln Sie dann wieder zur Registerkarte Google Search Console und klicken Sie auf die Schaltfläche Überprüfen.

Verify ownership

Sobald Ihre Website verifiziert ist, zeigt Google hier Ihre Search Console-Berichte an.

Sie müssen auch sicherstellen, dass sowohl die https- als auch die http-Version zu Ihrer Search Console hinzugefügt werden.

Damit teilen Sie Google mit, dass die https-Version Ihrer Website als die Hauptversion behandelt werden soll. In Kombination mit den 301-Weiterleitungen, die Sie zuvor eingerichtet haben, wird Google Ihre Suchrankings auf die https-Version Ihrer Website übertragen, und Sie werden höchstwahrscheinlich Verbesserungen bei Ihren Suchrankings feststellen.

Wir hoffen, dass dieser Artikel Ihnen geholfen hat, HTTPS und SSL in WordPress hinzuzufügen. Vielleicht interessieren Sie sich auch für unseren ultimativen WordPress-Sicherheitsleitfaden mit Schritt-für-Schritt-Anleitungen, um Ihre WordPress-Website sicher zu halten, oder für unsere Expertenauswahl der besten Analyselösungen für WordPress.

Wenn Ihnen dieser Artikel gefallen hat, dann abonnieren Sie bitte unseren YouTube-Kanal für WordPress-Videotutorials. Sie können uns auch auf Twitter und Facebook finden.

Offenlegung: Unsere Inhalte werden von unseren Lesern unterstützt. Das bedeutet, dass wir möglicherweise eine Provision verdienen, wenn Sie auf einige unserer Links klicken. Mehr dazu erfahren Sie unter Wie WPBeginner finanziert wird , warum das wichtig ist und wie Sie uns unterstützen können. Hier finden Sie unseren redaktionellen Prozess .

Das ultimative WordPress Toolkit

Erhalte KOSTENLOSEN Zugang zu unserem Toolkit - eine Sammlung von WordPress-bezogenen Produkten und Ressourcen, die jeder Profi haben sollte!

Reader Interactions

406 KommentareEine Antwort hinterlassen

  1. Syed Balkhi says

    Hey WPBeginner readers,
    Did you know you can win exciting prizes by commenting on WPBeginner?
    Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
    You can get more details about the contest from here.
    Start sharing your thoughts below to stand a chance to win!

  2. ammar says

    Hi, if i’m using the 1st method, do I need to follow the Submit my HTTPS Site to Google Search Console step also after that?

    TQ

  3. Swen says

    I installed the Really Simple SSL plugin, which states that you should manually replace every http:// in all .css and .js files to //. That doesn’t sound really simple to me. As a beginner I set up a simple website with a couple of pictures. Is it common that http:// statements are in these files?

  4. Lucas says

    Hi,
    When adding the code to .htaccess, i get a „too many redirects“ error. I tryed adding to the existing code above, below, and also erasing the existing code and using only the new. All three option get too many redirects.

    Is there something I should change there? Thanks in advance for your help!

  5. Sotir Sotirov says

    I’ve tried using the plugin but when I do the website becomes not accessible. I’ve tried the manual approach but once I’ve changed the addresses in WP settings the site becomes not accessible again.

    • WPBeginner Support says

      You would want to reach out to your hosting provider to ensure that your SSL certificate is connected to your domain correctly and they should be able to help :)

      Admin

  6. Mike Ashworth says

    I am about to make the change to SSL and will be following the guidance in te article, initially using the really simple ssl plugin. Before i begin i have a quick question.

    If I use the really simple ssl plugin, which takes care of everything, i can leave the general settings in wordpress for wordpress address and site address as http rather than change to https as the plugin will be taking care of it?

      • Mike Ashworth says

        Thanks for confirming. I have one other rquestion.

        having just activated lets encrypt ssl on siteground for a website, i am asked wther i want to switch the following on or leave it off.

        HTTPS Enforce – Forces your site to work entirely over an encrypted HTTPS connection. The redirect is performed on server level and works for any website.

        Do i leave this off as the really simple ssl plugin will take care of this as well?

        • WPBeginner Support says

          Yes, you can leave that off, you would only want to use that should there be any issues with the plugin or Google finding http links

        • Mike Ashworth says

          Thanks for your advice. WP Beginner is such an awesome website. Keep up the great work!

  7. stephan says

    I want to thank you a lot. I have been looking for the errors over 12hours and get it done with better replace plugins. Thanks a lot dear.

  8. Peter Wilson says

    Can someone tell me, do I replace the contents on my.htaccess. file with the suggested code or do I place it and the beginning/end of the eisting entry.

      • Peter Wilson says

        Thanks for the quick reply. So, would that be after the existing and before the # END WordPress, or does it go after the .

        • WPBeginner Support says

          That should not matter, it may be a good idea to do it after should you need to remove the code in the future :)

  9. Arif Ahmed says

    When I enable „WordPress 301 redirection to SSL“ option from „Really Simple SSL Plugin“ it works fine, but it removes query parameters. For example, when I get users from Adwords campaign it strips off gclid parameters.

    Please guide

    • WPBeginner Support says

      You would want to reach out to Really Simple SSL’s support to see if there is an option for query strings.

      Admin

  10. Oswald Porter says

    Thanks for your helpful article.
    The manual SSL/HTTPS set up seems be be working for the main site.
    However the mixed content error (images) still appears after using the Better Search Replace plug-in.
    At Media Library, images appear with ‚https‘, but not at the site’s each post
    Indeed, at all posts, when I right-click on the post image > ‚Copy image address‘, it shows:
    http://
    Ideas? Thanks in advance.

  11. Kathy says

    Hi,

    I used this tutorial on many sites and it works like a charm. Thanks for that.

    Do you know if I can also use it to update my multisite(s). Or are additional steps needed?

    • WPBeginner Support says

      Depending on how your multisite is set up there are normally more steps involved. If you reach out to your hosting provider they can normally help

      Admin

  12. Oz says

    Fantastic and straightforward!

    What steps do we need to take to make sure our social share count (e.g., Facebook, Twitter) are still available?

    • WPBeginner Support says

      You could try 301 redirecting the http articles to https but unless I hear otherwise, social media sites see the two as different links so you are likely going to lose your shares unless they have added a method to update your share counts.

      Admin

    • WPBeginner Support says

      There are multiple possible reasons for a change in traffic so it is hard to say if that is the only reason or if there were other reasons for a drop in traffic.

      Admin

  13. Shawn says

    Thank you for such a great piece of content.
    It seems like using the Really Simple SSL plugin is way easier than changing codes and scripts on my own.

    My question – what if the plugin did not get updated in the future? Is this going to cause a problem for our urls?

    And, after installing the SSL from my web host, all I need to do is to activate Really Simple SSL plugin and everything will be redirected to https?

    Shawn

    • WPBeginner Support says

      It would depend on what changes in WordPress‘ core code and how long it has not been updated for the possible issues. The plugin should automatically update your content that it is able to use HTTPS without you needing to modify anything on your end if you wanted.

      Admin

  14. Nathaniel says

    Just wanted to say thank you. I was not looking forward to doing this, but you’re guide made it easy and quick. Thanks!!!

  15. Sheri Ellis says

    I made the mistake of following your manual instructions before our SSL cert had been installed. All I did was edit the general settings for the URL to https. And now the site is hosed. I’ve been editing every PHP file to include:
    define( ‚WP_HOME‘, ‚http://mysite.com‘ );
    define( ‚WP_SITEURL‘, ‚http://mysite.com‘ );

    and it’s being ignored. So now my site is hosed. FYI I’m using WordPress 5.1.1 which appears to have significant changes. Help!

  16. John J Cooke says

    This made making the switch a snap. I was sitting on the ssl cert with no sure way how to convert. Really appreciate the easy instructions.

  17. Mandee says

    Oh my goodness, THANK YOU! I’ve reached out to my hosting company, as well as a developer. They both made it seem like an impossible task to do on my own. Just took care of this is literally 30 seconds because of you. I can’t thank you enough! I wish I would have found this article sooner—would have saved me a lot of headache!!

  18. Jerry says

    Hi,

    I tried twice your step guide end everything worked great. Now that i have SSL i am trying to migrate but there is a problem on the final step, so it cannot be finalized. Is it a problem i had Lets Encrypt on old server and now that the new one has another, to have caused a problem. Would you recommend remove SSL on old hosting and after that using dublicator to start the articles process?

    • WPBeginner Support says

      Who has your SSL should not be a factor for it not working, you could try to see if that works but it is normally due to another cause.

      Admin

  19. BILAL ALI AHMAD says

    Hi,

    I applied all steps and https version is working fine on my website but the non-https version is still accessible when I type http: mysite.com

    how to resolve this issue?
    Also when I click on my google search link for my website user also lands on non-https version and after that if I access the website again it comes with https
    please tell me how to resolve this issue?

    • WPBeginner Support says

      If you already submitted your site to Google’s Search console then Google may have cached the http version in their search. For the http version being available, you may want to ensure the redirects were all saved.

      Admin

  20. Marc-Lyon says

    Thanks for the great tutorial. Only issue I’m stuck with is that URLs with www appended give an error message in browser:

    „This site can’t provide a secure connection uses an unsupported protocol.
    ERR_SSL_VERSION_OR_CIPHER_MISMATCH
    Unsupported protocol
    The client and server don’t support a common SSL protocol version or cipher suite.“

    I’ve checked and both non-www and www versions have valid SSL certificates. Any idea why the www version is not working?

    • WPBeginner Support says

      Start by reaching out to your hosting provider to ensure they don’t have a setting on their end for the www specific version of your site.

      Admin

      • Marc-Lyon says

        Managed to sort it out. Cloudflare was causing the issue.
        Solution: disable and re-enable Universal SSL under Crypto settings.

        • WPBeginner Support says

          Glad you were able to find the cause and thanks for sharing the solution should anyone else run into the issue :)

  21. illy says

    All my images were inserted with http protocol. I used Better Search Replace to fix this and it worked like a charm!

    thank you

  22. Didier says

    I have a problem with the redirect from http to https.

    Using the above mentioned code in the .htaccess file,

    my index page http:// example.com redirects to httpS:// example.com

    BUT

    A subpage http:// example.com/sublink does NOT redirect to https:// example.com/sublink

    Does anybody know how to solve this?

    Thank you!

    • WPBeginner Support says

      You may want to reach out to your hosting provider to ensure they are not overriding any redirects on your site or if they see the code was copied incorrectly.

      Admin

  23. Jason says

    Yeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeees! The first WP edit that has ever worked first time for me! I’m taking the rest of day off to celebrate.

    :-)

  24. Rafaqat Ali says

    Hi thanks for the article, I have shifted my site to ssl by using the article elaborated above.
    Let me clear a few things:
    1- I have added a new property in Google search console with https:// should I delete the http:// property or remain the both.
    2- How long it will take to show google search data in the search console report.
    3- Should I make a 301 redirect to https:// version.
    4- How to get all my backlinks to https:// version.
    ( i have submitted the XML sitemap and robots..txt file also with new property)
    Thanks for your time

    • WPBeginner Support says

      Hey Rafaqat,

      If you have set up 301 redirect to your HTTPS urls, then you can leave them both. They would start appearing in search very soon, however of your redirects are properly setup you wont see any difference in your traffic or search rankings.

      Admin

  25. Eva says

    Hi and thank you for the detailed tutorial
    I have activated the ssl protocol on a new wordpress installation and after the activation the site’s started opening with https and green padlock ( all pages, with and without www search and if searching http version) even the admin area as far as the theme and editor , however the wordpress and site URL fields in the settings General page still need to be changed to https as they appear as http and any new publication (so as the ones alredy been there) has http link and when editong page appearancefrom main menu it shows exclamation mark oven the secure connection padlock
    In that case do I need to go thru all process or after updating the general settings page to https it will be ok ?
    It’s my first time doing that and I prefer ( if have to) to do it manually by the 2 method as it very well explained
    Thanks

  26. Bernard Brillo says

    I’ve tried following the manual tutorial but I end up seeing a blank white page on my homepage and all of my other page are now inaccessible. My website is hosted in Amazon and I’m also using W3 total cache.

    Do I need to do something else to make this work?

    Any suggestions will be much appreciated.

    • Donatas Vaiciulis says

      On my website was W3 total cache, when I disabled it worked everything fine. I think after htaccess edit needed to reinstall plugin and do w3 settings again. Not tried yet, soon will try.

  27. Karo Itoje says

    Hello,

    As usual thanks for the detailed tutorial. I decided to do the manual option (option 2) because it seemed simple enough to follow through. However when I pasted the second code for nginx servers into configuration file (wp-config.php) I got a syntax error. So I had to remove the code. But I will still like to follow through with that option so if you can please maybe take a look at that code again and correct it then I’ll really appreciate it.

    Also just to get this clearly, it is either:

    „set up WordPress redirects from HTTP to HTTPS by adding the following code to your .htaccess file.“

    OR THIS

    „If you are on nginx servers (most users are not), then you would need to add the following code to redirect from HTTP to HTTPS in your configuration file:“

    Not both right?

  28. Rohan Kothari says

    Hi,

    I am planning to start an e-commerce store. Do I need to purchase a wildcard SSL certificate and a dedicated IP to enable payments on my website or will the free SSL certificate bundled with web hosting plans be adequate?

  29. Oliver says

    Hi Guys,

    1st off a great and helpful article, thanks. I have changed my site from http to https and it took a lot less time than I expected, using the Better Search and Replace manual method. But now I can’t seem to change the address of the http version in the Google Search Console. It has both of the sites there but won’t allow me to swap. Is this necessary to do? It seems as if the redirects are working. Should I get the https site indexed as much as possible or will google do that with the http redirects anyway?

    • WPBeginner Support says

      Hi Oliver,

      If you have both sites in the search console and a redirect in place, then Google will automatically detect the transition and will start showing reports for your HTTPS site.

      Admin

  30. Victor Fernando says

    I used the first method, although I have experience in programming, I don’t have it in wordpress and I don’t dare to get my hands on the code even though it’s not that complicated.
    the first method worked i.e. installing the free plugin version.
    Thanks for the tip

Eine Antwort hinterlassen

Danke, dass du einen Kommentar hinterlassen möchtest. Bitte beachte, dass alle Kommentare nach unseren kommentarpolitik moderiert werden und deine E-Mail-Adresse NICHT veröffentlicht wird. Bitte verwende KEINE Schlüsselwörter im Namensfeld. Lass uns ein persönliches und sinnvolles Gespräch führen.