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

Så här flyttar du WordPress från en lokal server till en Live site (2 metoder)

Många WordPress-användare föredrar att arbeta med sina webbplatser på en lokal server på datorn. På så sätt kan du arbeta privat med din webbplats innan du gör ändringarna tillgängliga online.

Så småningom måste du flytta den till en live-server för att göra den tillgänglig för onlinebesökare. Denna övergång är avgörande för att säkerställa att din webbplats fungerar korrekt på live-webbplatsen.

Vi har arbetat med många lokala webbplatser, så vi var tvungna att lära oss det enklaste sättet att överföra innehåll till levande webbplatser.

I den här artikeln ger vi dig steg-för-steg-instruktioner om hur du flyttar WordPress från en lokal server till en live-webbplats.

How to move WordPress from local server to live site (2 methods)

Varför flytta WordPress från en lokal server till en Live site?

Att bygga din WordPress blogg på en lokal server är ett säkert sätt att testa ändringar på din website utan att påverka besökarna.

När you har slutfört finslipningen av din website är nästa steg att flytta från din lokala server till en live site.

Låt oss visa dig två sätt att flytta din site från en lokal server till en live site.

Den första metoden använder ett plugin för att flytta WordPress och rekommenderas för Beginnare.

I den andra metoden visar vi dig hur du manuellt flyttar WordPress från en lokal server till en live site.

Du kan välja den metod som fungerar bäst för dig:

Innan du flyttar din WordPress webbplats

Du måste ha några saker på plats för att migrera WordPress från en lokal server till en live-server.

Först antar vi att du har en WordPress-webbplats som körs på en lokal server (även kallad localhost) på din dator och att du har full tillgång till den.

Därefter måste du ha ett domain name och ett webbhotell.

Vi har hört otaliga historier från nybörjare som började med dåliga eller gratis webbhotell och ångrade sig. Enligt vår erfarenhet är valet av rätt webbhotell avgörande för att en webbplats ska bli framgångsrik.

För att göra ditt beslut enklare rekommenderar vi att du använder Bluehost. De är ett officiellt rekommenderat webbhotell för WordPress, och de ger WPBeginners användare en exklusiv rabatt + gratis domän och SSL.

I grund och botten kan du komma igång för så lite som $ 1.99 per månad.

Om du vill ha ett bra Bluehost-alternativ kan du titta på Hostinger. De erbjuder också en exklusiv rabatt till WPBeginners användare med ett gratis domain name.

Om du har råd att betala lite mer, kontrollera då SiteGround. De har också ett specialerbjudande för WPBeginners läsare.

Om du behöver hjälp med att skapa din website kan du följa vår Step-by-Step guide om hur du skapar en website.

Slutligen behöver du ett FTP-program och veta hur du använder FTP för att uppladda din lokala server till live-sajten.

Är du redo? Låt oss börja flytta din WordPress site.

Video Tutorial

Subscribe to WPBeginner

Om du föredrar skriftliga instruktioner är det bara att fortsätta läsa.

Metod 1: Överför WordPress från den lokala servern till Live Site med hjälp av ett tillägg för migrering (rekommenderas)

Den här metoden är enklare och rekommenderas för Beginnare. Vi kommer att använda ett plugin för WordPress-migrering för att flytta WordPress från localhost till en live site.

Step 1: Installera och konfigurera tillägget Duplicator

Först måste du installera och aktivera pluginet Duplicator på din lokala site. För mer detaljer, se vår Step-by-Step guide om hur du installerar ett plugin för WordPress.

Pro tips: Det finns också en Pro-version av Duplicator som erbjuder säkra backups, molnlagring, enkel återställning av webbplatser och mer.

Vid aktivering måste du gå till Duplicator ” Packages page och klicka på knappen ’Create New’.

Create new package for migration

Då kommer du till en vy där du kan ge din backup ett namn.

Klicka sedan på knappen ”Next”.

Name backup package

Duplicator kommer nu att runna några tester för att se om allt är i order.

Om alla punkter är markerade med ”Bra” klickar du på knappen ”Bygg”.

Build package

Denna process kan ta några minuter, beroende på storleken på din webbplats. Du måste lämna den här fliken öppen tills den är klar.

När du är slutförd ser du alternativ för download av paketen ’Installer’ och ’Archive’. Du måste klicka på länken ”One-Click Download” för att ladda ner båda filerna till din dator.

Download package files

Filen ”Archive” är en komplett kopia av din WordPress site. Den innehåller alla WordPress core-filer samt dina images, uploads, themes, plugins och en backup av din WordPress database.

Filen ”Installer” är ett skript som kommer att automatisera hela migreringsprocessen genom att packa upp archive-filen som innehåller din website.

Step-by-Step 2: Skapa en Database för din Live WordPress website

Innan du kan runna installeraren eller uploada WordPress-webbplatsen från localhost till ditt webbhotell måste du skapa en MySQL-databas för din new live website.

Om du redan har skapat en MySQL-databas kan du hoppa över det här steget.

För att skapa en database måste you gå till cPanel dashboard på ditt webbhotell account. Leta sedan upp sektionen ”Databases” och klicka på ikonen ”MySQL Database Wizard”.

MySQL Database Wizard

På nästa vy finns det ett fält för att skapa en new database.

Ange bara ett namn på din database och click på knappen ”Create Database”.

Name new database

cPanel kommer nu att skapa en new database åt you.

Efter det måste du enter ett användarnamn och password för din nya användare och sedan click the ”Create User” button.

Create new database user

Nu måste du add to den användare som du just skapat till databasen.

Klicka först på checkboxen ”All Privileges”.

Check all privileges

Sedan rullar du ner och klickar på knappen ”Make Changes” för att save your changes.

Din database är nu redo att användas med din site WordPress. Se till att du obs/observerar databasens namn, användarnamn och password. Du kommer att behöva denna information i nästa steg.

Steg 3: Ladda upp filer från den lokala servern till WordPress-webbplatsen i realtid

Nu måste du uploada archive- och installer-filerna från din lokala site till ditt webbhotell.

Anslut först till din Live site med hjälp av en FTP-klient. När du har anslutit, se till att rotkatalogen på din website är helt tom.

Normalt sett är root directory foldern /home/public_html/.

Vissa webbhotell för WordPress installerar WordPress automatiskt när du registrerar dig. Om du har WordPress-filer där måste du ta bort dem.

Efter det kan du uploada archive.zip och installer.php-filerna från Duplicator till din tomma root directory.

Upload archive and installer files

Steg 4: Run på migreringsskriptet

Följ efter att du har uppladdat migreringsfilerna, du måste besöka följande URL i din webbläsare:

http://example.com/installer.php

Glöm inte att ersätta ”example.com” med ditt eget domain name.

Detta kommer att starta migreringsguiden för Duplicator.

Installern kommer att runna några tester och initiera skriptet.

Duplicator migration wizard step 1

Under Setup section kommer du att bli ombedd att enter din MySQL server, databasnamn, användarnamn och password.

Din värd kommer troligen att vara en lokal värd. Därefter anger du uppgifterna för den databas som du skapade i det tidigare steget.

Klicka sedan på knappen ”Validate” för att kontrollera att de detaljer du har enter är korrekta.

Validate settings

Därefter klickar du på knappen ”Nästa” för att fortsätta.

Duplicator importerar nu din WordPress backup av databasen från archive till din new database.

Den kommer också att uppdatera webbadresser som pekar på den lokala webbplatsen och din nya live-webbplats.

You can now click on the ”Admin Login” button to enter the WordPress admin area of your live site.

Admin login

När du loggar in på din live site kommer Duplicator automatiskt att städa upp installationsfilerna.

Nu är allt klart. Du har utan problem flyttat WordPress från den lokala servern till din live site.

Metod 2: Överför WordPress manuellt från den lokala servern till Live-webbplatsen

I den här metoden visar vi hur du manuellt flyttar WordPress från den lokala servern till din live site. Det är användbart om den första metoden inte fungerar eller om du föredrar att göra det manuellt.

Step-by-Step: Exportera lokal WordPress Database

Det första du behöver göra är att exportera din lokala WordPress database. Vi kommer att använda phpMyAdmin för att göra det.

Om du inte är bekant med det kan du läsa vår guide till hantering av WordPress Database med phpMyAdmin.

Gå till http://localhost/phpmyadmin/ och klicka på your WordPress database. Därefter klickar du på knappen ”Exportera” högst upp i menyn.

Export from localhost

I alternativet ”Exportmetod:” kan du välja ”Snabb” eller ”Anpassad”. Custom ger dig fler alternativ för att exportera din databas.

Men vi rekommenderar att du väljer ”Quick” och sedan klickar på knappen ”Go” för att downloada din database.

Export WordPress database using phpMyAdmin

Step 2: Uppladda WordPress-filer till Live Site

Nu måste vi flytta all your website-filer till live site.

För att komma igång öppnar du din FTP-klient och ansluter till ditt konto på webbhotellet.

När du är ansluten till din live-webbplats ska du se till att du laddar upp filerna i rätt katalog. Om du till exempel vill att webbplatsen ska hostas på ”dinsite.com” ska du ladda upp alla filer i din public_html-katalog.

Välj nu dina lokala WordPress-filer och uploada dem till din live server.

Upload WordPress files FTP

Step-by-Step 3: Skapa en MySQL Database på din Live site

Medan din FTP-klient uppladdar dina WordPress-filer kan du börja importera din database till live-servern.

De flesta WordPress-hostingleverantörer erbjuder cPanel för att hantera ditt hostingkonto, så vi kommer att visa dig hur du skapar en databas med hjälp av cPanel.

Först måste du logga in på din cPanel dashboard och click på ”MySQL Database Wizard” icon, som finns i ”Databases” section.

Select MySQL database wizard

På nästa vy kan du skapa en new database.

Du måste ange ett namn för din databas och sedan klicka på ”Create Database”.

Name and create new database

cPanel kommer nu automatiskt att skapa en new database åt you.

Därefter måste du ange ett användarnamn och lösenord för din nya användare och sedan klicka på ”Create User”.

Create new database user

Efter det måste du add to den användare du just skapat till databasen.

Kontrollera först checkboxen ”All Privileges”.

Check all privileges checkbox

Sedan rullar du ner och klickar på ”Make Changes” för att save your changes.

Du har utan problem skapat en new database för din live WordPress site.

Step 4: Importera WordPress Database till Live Site

Nästa steg i processen är att importera din WordPress database.

Gå till din cPanel-instrumentpanel, bläddra ner till avsnittet ”Databaser” och klicka på ”phpMyAdmin”.

Click on phpMyAdmin

Detta tar dig till phpMyAdmin, där du vill klicka på databasen som du just skapade ovan. phpMyAdmin visar din nya databas utan tabeller.

Klicka sedan på tabben ”Import” högst upp i menyn. På sidan import klickar du på knappen ”Choose File” och väljer sedan database-filen från den lokala site som du saved i det första steget.

Import database via phpMyAdmin

Därefter klickar du på knappen ”Go” längst ner på sidan. Din database kommer automatiskt att importeras till phpMyadmin.

Step 5: Ändra URL:en för webbplatsen

Nu måste du ändra webbplatsens URL i din database så att den ansluter till din live WordPress-webbplats.

I phpMyAdmin letar du efter wp_options-tabellen i din database som du just importerade ovan.

Om you changed your database prefix, then instead of wp_options, it might be {new_prefix}_options.

Klicka sedan på knappen ”Browse” bredvid wp_options. Eller klicka på länken i sidebaren för att öppna upp den page som innehåller en lista över fälten i tabellen wp_options.

Browse the wp options table

Sedan, i options_name column, måste du leta efter alternativet siteurl.

Klicka sedan på ikonen ”Edit”.

Edit siteurl in phpMyAdmin

Du får upp ett fönster där du kan edit:a fältet.

I inmatningsrutan option_value ser du webbadressen till din lokala installation, som kommer att vara något i stil med http://localhost/test.

Du måste infoga din nya site URL i detta fält, till exempel: https: //www.wpbeginner.com.

Sedan kan du save fältet genom att clicka på knappen ”Go”.

edit the siteurl field

Därefter måste du följa samma steg som ovan för namnet på hemalternativet. Menyn wp_options kan vara några pages lång. Vanligtvis kommer home page-alternativet att finnas på den andra sidan.

Uppdatera sedan hem-URL:en så att den är densamma som URL:en för din live site.

Step-by-Step 6: Konfigurera din Live site

Nu när du har importerat databasen och uppladdat ditt content är det dags att konfigurera WordPress.

Just nu bör din site visa felmeddelandet”Error establishing a database connection”.

För att fixa detta ansluter du till din website med en FTP-klient och öppnar filen wp-config.php.

Du kommer att leta efter följande rader med kod:

// ** MySQL settings - You can get this info from your web host ** //
/** The name of the database for WordPress */
define( 'DB_NAME', 'database_name_here' );
/** MySQL database username */
define( 'DB_USER', 'username_here' );
/** MySQL database password */
define( 'DB_PASSWORD', 'password_here' );
/** MySQL hostname */
define( 'DB_HOST', 'localhost' );

Du måste ange namnet på databasen, användarnamnet och passwordet som du skapade tidigare.

Save sedan filen wp-config.php och uploada den tillbaka till ditt WordPress webbhotell server.

Nu, när you besöker your website, ska den vara live.

Efter det måste du logga in på din WordPress adminpanel och gå till Settings ” Allmänt. Sedan, utan att ändra något, rullar du längst ner och klickar på knappen ”Save Changes”.

Save general settings

Detta kommer att se till att din sites URL är korrekt på alla andra ställen där den behöver vara.

När du har gjort det, gå till Settings ” Permalinks, rulla sedan ner och klicka på ”Save Changes” för att säkerställa att alla länkar till post fungerar bra.

Save permalinks settings

När du flyttar en WordPress-webbplats från en domän till en annan eller från en lokal server till en live site, kommer du att stöta på brutna links och saknade images.

Vi visar dig två sätt att uppdatera webbadresser. Du kan välja det som fungerar bäst för dig.

1. Uppdatera webbadresser med hjälp av Search & Replace Everything Plugin (rekommenderas)

Det säkraste sättet att åtgärda detta är att använda Search & Replace Everything. Det är ett kraftfullt WordPress-plugin som gör att du enkelt kan utföra massuppdateringar på din webbplats utan att skriva komplexa databasfrågor.

Först måste du installera och aktivera pluginet Search & Replace Everything.

Efter aktiveringen går du till sidan Verktyg ” WP Search & Replace.

Search and replace URLs from local to live site migration

Därefter måste du ange webbadressen till din lokala webbplats i fältet ”Sök efter” och webbadressen till din live-webbplats i fältet ”Ersätt med”.

Bläddra lite och klicka på ”Välj alla” under tabellerna. Detta säkerställer att insticksprogrammet letar efter den gamla webbadressen överallt i databasen.

Select tables

Klicka nu på knappen ”Förhandsgranska Sök & Ersätt” för att fortsätta.

Pluginet söker i din databas efter alla förekomster av den gamla URL:en och förhandsgranskar sedan resultaten.

Preview changes

Om allt ser bra ut klickar du på ”Replace All” för att spara ändringarna.

Du kommer att se en varning om de ändringar du gör. Klicka på ”Ja” för att fortsätta.

Pluginet kommer nu att uppdatera databasen och ersätta lokala webbadresser med din nuvarande webbadress.

2. Uppdatera webbadresser manuellt (Avancerat)

Ett annat sätt att uppdatera webbadresserna är att använda följande SQL-fråga:

UPDATE wp_posts SET post_content = REPLACE(post_content, 'localhost/test/', 'www.yourlivesite.com/');

Gå bara till phpMyAdmin, klicka på din databas och klicka sedan på ”SQL” i toppmenyn och lägg till frågan ovan.

Se till att du ändrar URL:erna till din lokala webbplats och din live-webbplats och klicka på knappen ”Go”.

Fixing WordPress images and broken URLs after moving to live site

Nu är det klart. Nu har du utan problem flyttat WordPress från din lokala server till en live site.

Förhoppningsvis är din live-webbplats igång och fungerar smidigt. Om du upptäcker några fel kan du kolla in vår guide till vanliga WordPress-fel för att få hjälp med felsökning.

Vi hoppas att den här artikeln hjälpte dig att flytta WordPress från en lokal server till en live-webbplats. Du kanske också vill se vår guide om att flytta en live-webbplats till en lokal server eller titta på den ultimata checklistan för webbplatsmigrering för praktiska steg för WordPress-migrering.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

Avslöjande: Vårt innehåll stöds av våra läsare. Det innebär att om du klickar på några av våra länkar, kan vi tjäna en provision. Se hur WPBeginner finansieras, varför det är viktigt, och hur du kan stödja oss. Här är vår editoriala process.

Avatar

Editorial Staff at WPBeginner is a team of WordPress experts led by Syed Balkhi with over 16 years of experience in WordPress, Web Hosting, eCommerce, SEO, and Marketing. Started in 2009, WPBeginner is now the largest free WordPress resource site in the industry and is often referred to as the Wikipedia for WordPress.

Den ultimata WordPress-verktygslådan

Få GRATIS tillgång till vår verktygslåda - en samling WordPress-relaterade produkter och resurser som varje professionell användare bör ha!

Reader Interactions

909 kommentarerLämna ett svar

  1. Syed Balkhi

    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. Thembi

    Hi guys tearing my hair out. Original site on local server works well on local server. The live site on the remote server works well on the live server. When I move it to the local host it gives me this php error when installing plugins… i have read all blogs and issue not resolved for me. I tried both the duplicator and manual process but still get this php error :(

    Warning: An unexpected error occurred. Something may be wrong with WordPress.org or this server’s configuration. If you continue to have problems, please try the support forums. (WordPress could not establish a secure connection to WordPress.org. Please contact your server administrator.) in C:\wamp\www\missflairword\wp-includes\update.php on line 457

    • WPBeginner Support

      Seems like your localhost install is unable to connect to the internet. This could happen if Apache is blocked by your network’s firewall. You need to allow apache access to the internet from your windows firewall settings.

      Administratör

  3. Checo

    Wow guys, this Tutorial was excellent, precise and very well detailed!!! Thank you very much, you helped me publish my first locally developed wordpress site right on the deadline without any mistakes. Best regards!

  4. Sam

    someone should tell me when you see a better word for Genius, because that is what you guys are. your tutorials has made me a lil’genius.

    Thanks guys

  5. Silvia

    Your tut is the best! I tried several times before and never was able to do it until now! genius! thanks!

  6. Angela

    What a LIFESAVER! I tried several other peoples suggestions and different plug-ins that are supposed to make it easy… Nothing worked until this! Thank you!

  7. gaurav Royal

    thankx a lot .. its working

  8. Ken

    I’ve followed all the steps given. When I access the live site I get everything I can without changing the media URLs.
    I can’t do that yet because I can’t login to the admin area. i get the following errors on the screen above the login box and valid logins are not accepted (checked with myPHP):

    Warning: session_start(): Cannot send session cookie – headers already sent by (output started at /home/cgbookss/public_html/wp-includes/functions.php:1) in /home/cgbookss/public_html/wp-content/plugins/event-commerce-wp-event-calendar/evntgen-scbooking.php on line 519

    Warning: session_start(): Cannot send session cache limiter – headers already sent (output started at /home/cgbookss/public_html/wp-includes/functions.php:1) in /home/cgbookss/public_html/wp-content/plugins/event-commerce-wp-event-calendar/evntgen-scbooking.php on line 519

    Warning: Cannot modify header information – headers already sent by (output started at /home/cgbookss/public_html/wp-includes/functions.php:1) in /home/cgbookss/public_html/wp-login.php on line 424

    Warning: Cannot modify header information – headers already sent by (output started at /home/cgbookss/public_html/wp-includes/functions.php:1) in /home/cgbookss/public_html/wp-login.php on line 437

    Have you any suggestions?

  9. geoff

    can’t seem to get the phpmyadmin to work locally. you seem to haven’t put that in, and the link you have provided to ”explain” how to use the phpmyadmin, refers to that running on c panel not locally.
    it would be good if you could explain, running phpmyadmin locally, through webmatrix for explain.

  10. rodrigo

    Was a great help, this tutorial. I had some 500 server errors fixed after editing the htaccess.php file. But I still have no access to the wp-admin dashboard? Anyone got the same emptiness on the backend link? what could be the fix?

  11. Charlie

    I have the same exact issue. Trying to find a solution for this but it seems like one isn’t mentioned here on this page, or in the comments.

  12. hokka

    I have troubles with my new site address. Everything else seems to work just fine.

    In phpmyadmin if I change the siteurl to direct the site to the correct subfolder, the website content disappears when the ”home” option value is correct. Then again if I also change my home-value into the same address as the files are in, meaning the same address as siteurl, then I see the content but the address is not what I wanted it to be. I’ve also tried to use Velvet Blues -plugin but nothing happened.

    In my case the WordPress url is different from website url, so basically the changes won’t affect in admin panel Settings.

    Thanks for this great tutorial.

  13. JulioC

    Not sure if was very lucky but in my case I followed all steps and everything worked perfect!!!

    Thanks a lot!

  14. WPBeginner Staff

    The other part of making backups is restoring your sites from backups. cPanel does not make that part easy. Configurations may differ from one site to another. Sometimes user may even want to move to a web host that does not offer cPanel. For more advanced users who can troubleshoot these issues, cPanel backups can be a good option. But for most beginners it can be difficult. There are other backup options as well, take a look at our pick of 7 Best WordPress Backup plugins.

  15. Joey

    BackupBuddy seems to be a bit of an overpriced option when you can simply back up a WP site via Cpanel … are there any other benefits for using BackupBuddy when backing up via Cpanel is easy and free?

  16. jeroen

    Hi, I’m still struggling withe the migration of my local hosted WP multisite to a webserver. Replaced all the urls’s as far as I can tell but still the navigation doens’t work. Ik can enter the root which shows the homepage correctle but clicking a navigation link I get this error.
    ”Not Found
    The requested URL /index.php was not found on this server.”

    Although the paths of the menu links(shown on hover) look fine. Any Idea where to go look to solve this? Thanks in advance.

  17. Tim

    After importing the database, I tried to do step 5. However, when I click on wp_options, i do not have an edit spot. It says ”current selection does not contain a unique column. Grid edit, checkbox, edit, copy and delete features are not available.”
    Why is this happening?
    Thank you

  18. nirali

    hello can anyone help me.. there is a image path error in hosting.. how to solve it?

  19. WPBeginner Staff

    You can find out your live site’s database information by vising phpMyAdmin through cpanel. Notice the database name, mysql host, mysql username, and password and then fill in that information in your live site’s wp-config.php file.

    On your local site go to localhost/phpmyadmin/ to find out the correct database name.

  20. allison ranieri

    I completed all the steps and now my live site just says Error Establishing database connection and I cannot access my localhost at all – it is just a white screen. When in Step 6 it said to change your config.php file I accidentally changed the info in my local config file instead of the one updated through MySql but I figured that one out and changed the info back in my local file to what I thought it was before, but now when I go to localhost/wordpress (where I had previously gone before) it just shows a white screen. And my live site says Error Establishing Database Connection. So confused. Any help would be lovely.

  21. Prabhjot kaur

    I want to ask something as if i upload my site as a live site then edit link will appear or not ?that are already shown in localserver.

  22. Enoch Ramal

    Almost there but I get this…

    Parse error: syntax error, unexpected ’define’ (T_STRING) in /home/klbensonsk/public_html/wp-config.php on line 31

  23. vanyoattila

    Hi, I have uploaded my first page with the help of this post and it has been working perfect since than. Now I have a problem with an other site. I went through all the critical points again and again but I have always the same issue. The site is working (with broken links) but I can’t log in to the admin site. I changed the database at phpmyadmin and the wp-config.php file also. They have the same username and same password so they have the same datas and yet I have the problem. How does it possible?

  24. Sybrin

    Hi there, my WordPress website has just moved to a new ip address, and I followed the steps at the bottom to fix broken links. It said that it fixed them but my website is still not displaying properly. Some images are displaying as broken images and some image sliders are not showing up at all. The website also seems a hell of a lot slower. How do I fix this all?

  25. Sybrin

    Hi there, my WordPress website has just moved to a new ip address, and I followed the steps at the bottom to fix broken links. It said that it fixed them but my website is still not displaying properly. Some images are displaying as broken images and some image sliders are not showing up at all. The website also seems a hell of a lot slower. How do I fix this all?

  26. vinamr

    Do i have to install WordPress through my cpanel? or do i straight away upload the files through ftp?

  27. up

    I have had a hard time finding an answer to a simple question: Do you upload the wordpress folder or the contents of the wordpress folder to public_html

  28. Krizia Bianca

    Thank you so much, this tutorial works fine for me! I uploaded my wordpress to a live site. And it run smoothly! :D

  29. GSR

    Hi. I’ve followed all the steps (I think so) and now I no longer have the error message about not having a database connection – instead I now just have a blank white screen. Can you tell me where I’ve gone wrong?

  30. Malik Talib Hussain

    Thanks a lot for such a descriptive guide,I have uploaded my site successfully using this guide.

  31. John

    Thanks for sharing this. It worked for me at a go.

  32. Daniel

    Is it normal that in the step 6, after I updated the wp-config.php file, instead of appearing the homepage of the site (as I viewed in localhost) it appears the installation process?

    PD: I have completed all the previous steps.

  33. duke

    Very easy, some tips to remember, i have to wait a while to transfer local wordpress site to public_html because of the number of themes i am using.

    I forget to grant access to the db user, so i did it and it worked.

    All steps is important, the sql command works great.

    I rename .htaccess to .htaccess_old and it works

    then just update and save permalinks.

    Very easy fix for everything.

  34. BJH

    Thanks for the tutorial.

    Unfortunately it doesn’t work for me. I think that there are so many variables with something like this. Your steps work for you, with your scenario, but for someone else it can be very easy to end up with something else which stops the process working. Migrating wordpress is a real chore in my experience.

    • Lloyd

      I have 30+ years of IT experience including design of large 1000+ user infrastructure, plus extensive hands on program coding.

      I have used WordPress to create one site and I am really happy with the result.

      However, I would have to say that for anything other than simply creating a single production site, WordPress is unbelievably complicated to use for anyone contemplating creating multiple sites, or creating a dev to prod environment. Absolute unmitigated nightmare.

      Is there is anything that the WordPress developers could do to make the actual architecture easier to understand and use that would be great.

  35. Matthew

    Hi,
    Great tutorial, thanks a bunch. I’m doing my first wp redesign for a client who already has a well established blog with posts images etc. I’ve exported all of her data into the local site, designed a new theme with new pages etc. While importing her posts locally and selecting the option to download attachments, the posts have appeared but none of the images and I’m about ready to upload everything to her server.

    Do I just upload the theme files and in doing so will my modifications be present? Or do I need to upload everything as this tutorial suggests. She has over 2000 posts, an image for each, and I’ve got new images, pages, and layout.

    If you can either make a tutorial for moving/importing a redesigned or newly designed blog into an existing blog with posts pages etc. Or point me in the right direction, That would be great.

    The client won’t give me access to the server itself and insists on doing the ftp himself because he saw on the news that he could get his identity stolen or some such nonsense. I explained that he could set access restrictions on a separate login but he insists he do it.

    And the don’t want me working directly on the site because they’re worried about downtime while I update and build it.

    You can’t always be picky when it come to clients and I don’t really have a choice I’m just about done.

  36. Emilio

    Thank you for the tutorial!
    But now that I’ve imported all my site, the logo isn’t showing and my Dashboard doesn’t show the theme functions, I run Divi from Elegant Themes.

  37. Martin

    I’ve imported my database and wordpress install, but none of my pages are showing when I login to the admin panel? I’ve activated the theme, but no pages? Please help!

  38. WPBeginner Staff

    Please go to the admin area -> Settings and make sure that you are using the correct Site Address and WordPress Address.

  39. Christine

    Good day.
    Thanks for this easy to follow tutorial.
    I managed all the steps and my site seems to be connected, except that my theme is missing. All the files are in place with their stylesheets, but the site seems to be displaying plain html.Has anyone else experienced this?
    Not sure how to go about fixing it.

  40. tawanda masvanhise

    thanks for the great tutorial! l have a problem after doing all the steps; my website is displaying
    Error establishing a database connection
    how can i solve this problem?

  41. Claudio Henrique Amorim

    Thank you so much.
    I’m definitely a wp beginner and this post was just of an wonderful help. Everything went on flawless.
    I’m really enjoying working as a web designer and wp developer. And I hope I’ll get more and more of these kind of jobs, and more challenging ones. I learned so much while doing this very first one.
    Thank you again.

  42. WPBeginner Staff

    Seems like your domain is not yet ready or you have uploaded WordPress in the wrong directory on your web server. Please contact your web hosting provider for support.

  43. Elliot Lee

    HELP!!

    I have completed step 1 to step 6, but my site still displays:

    Future home of something quite cool.
    If you’re the site owner, log in to launch this site
    If you are a visitor, check back soon.

    Why is this happening???

  44. Elliot Lee

    I have completed step 1 to step 6, but my website still displays:

    Future home of something quite cool.
    If you’re the site owner, log in to launch this site
    If you are a visitor, check back soon.

    What could be the problem???

  45. Elliot Lee

    HELP!!! Why am I receiving this error in step 4?

    SQL query:


    — Database: `wordpress`

    — ——————————————————–

    — Table structure for table `wp_commentmeta`

    CREATE TABLE `wp_commentmeta` (

    `meta_id` bigint( 20 ) unsigned NOT NULL AUTO_INCREMENT ,
    `comment_id` bigint( 20 ) unsigned NOT NULL DEFAULT ’0’,
    `meta_key` varchar( 255 ) DEFAULT NULL ,
    `meta_value` longtext,
    PRIMARY KEY ( `meta_id` ) ,
    KEY `comment_id` ( `comment_id` ) ,
    KEY `meta_key` ( `meta_key` ) ) ENGINE = InnoDB DEFAULT CHARSET = utf8 AUTO_INCREMENT =1;

    MySQL said:

    #1046 – No database selected

    • WPBeginner Staff

      Before you can run this query you need to select the database you want to run it on. If you are using phpMyAdmin then select the database and then click on the SQL to run the query.

      • Elliot Lee

        ok thanks

  46. Thinh

    Hi, thanks for a easy guide.

    But I wonder how I can export to live when WordPress is already installed live? I redesigned the website from scratch, only thing is that I used the same theme. What would be the best way to get this live?

    Thanks, keep up the good work!

  47. PixelstoLife

    Great tutorial, thanks for the help.
    Like some others, the up_user updates don’t work and the links on my site are still calling the localhost. I’ve also been booted out as the admin user and cannot login to update permalinks etc.
    I’ve found a tutorial to re-instate an admin user via phpmyadmin so I’ll give that a go and see if I can get back in!
    Cheers

  48. Ben

    Great guide, but having a little bit of trouble and wondering if you can help.

    I’ve done everything above, but when I try to go on to the …/wp-admin page I get this: ’Warning: require(/home/username/public_html/wp-includes/pomo/mo.php): failed to open stream: No such file or directory in /home/username/public_html/wp-settings.php on line 76’

    Any ideas?

  49. lokesh

    I m facing a prlessphp fatal error: load error: failed to find /home1/eminenta/public_html/server/Suman_Creations/wp-content/themes/theme49413/bootstrap/less/bootstrap.lesslessphp fatal error: load error: failed to find /home1/eminenta/public_html/server/Suman_Creations/wp-content/themes/theme49413/style.less oblem when i move my website from local server to live server

Lämna ett svar

Tack för att du väljer att lämna en kommentar. Tänk på att alla kommentarer modereras enligt våra policy för kommentarer, och din e-postadress kommer INTE att publiceras. Vänligen använd INTE nyckelord i namnfältet. Låt oss ha en personlig och meningsfull konversation.