If you are moving content from another WordPress site or blog service, you can use the built-in WordPress import tools. This guide covers how to perform an import using the graphical user interface and how to import larger files reliably via the command line.
Preparation: Exporting Content
Before you can import content, you must create an export file from the source site.
Log in to the WordPress dashboard of the source site.
Navigate to Tools > Export.
Select the content to export (usually "All content").
Download the file to your computer. The file extension will be
.xml.
Option 1: Import via the Dashboard
This method is suitable for small to medium-sized files.
Log in to your WordPress site hosted at Seravo.
Navigate to Tools > Import.
Find WordPress from the list and click Install Now (if the tool is not already installed).
Click Run Importer.
Click Choose File and select the XML file you downloaded earlier and click Upload file and import.
In the next step, you can assign the content to specific users. Make sure to check the box Download and import file attachments to ensure images are transferred.
Note: If the file is large, the import may stall, and the browser may display an error message (e.g., 504 Gateway Timeout). In such cases, the import should be performed via the command line.
Option 2: Import via the Command Line (WP-CLI)
For large imports (e.g., thousands of posts or hundreds of megabytes of images), we recommend using the WP-CLI tool. It bypasses browser timeouts and is significantly faster.
1. Transfer the XML File to the Server
Transfer your export file to the server via SSH or SFTP, for example, to the /data/wordpress/ directory.
2. Run the Import via SSH
Connect to your site via SSH and run the following commands:
Install the importer tool if needed:
wp plugin install wordpress-importer --activate
Run the import:
wp import /data/wordpress/your-filename.xml --authors=create
--authors=create: Automatically creates new authors if they do not already exist.The import will automatically download attachments if they are available from the original source.
3. Importing Images and Attachments Separately
Sometimes you may want to import only the attachments or ensure they were processed correctly. You can do this with the following command:
wp import /data/wordpress/your-filename.xml --authors=skip --fetch-attachments
Common Issues
HTTP 504 / Timeout: The file is too large for the browser. Use WP-CLI instead.
Missing Images: Ensure the original site is still online. The importer attempts to download images from the source during the process. If the original site is already offline, images cannot be fetched automatically.
Upload limit: If you encounter PHP upload limits in the dashboard, WP-CLI is the best solution as it does not follow the same restrictions.
