Content
-
Exporting data from your current WordPress site
-
Importing data to Shifter Headless Site
Notes
Shifter Headless only accept SQL data (Post, Page or other content) for data migration.
Exporting data
We recommend using All-in-One WP Migration to migrate data.
1. Navigate to WordPress dashboard
![](/wp-content/uploads/2024/03/201990225-8ed54e47a091aa29d1e9d2e8.png?expires=1619749051&signature=c66d845a600490c65f89c50105a32f205d62a2ee3db6e4416895e34499cdf39c)
2. Add filter to exclude some directories
Directories should be exclude are
-
wp-content/ai1wm-backups
-
wp-content/languages
-
wp-content/mu-plugins
-
wp-content/plugins
-
wp-content/themes
-
wp-content/upgrades
-
wp-content/object-cache.php
-
wp-content/uploads (if you don’t need to copy media)
-
or other directories you don’t need to copy
Here is sample code for excluding directories. You can copy and paste following code to functions.php
add_filter('ai1wm_exclude_content_from_export', function($exclude_filters) {
$exclude_filters[] = 'ai1wm-backups';
$exclude_filters[] = 'languages';
$exclude_filters[] = 'mu-plugins';
$exclude_filters[] = 'plugins';
$exclude_filters[] = 'themes';
$exclude_filters[] = 'uploads';
$exclude_filters[] = 'upgrades';
$exclude_filters[] = 'object-cache.php';
return $exclude_filters;
});
Never forget to remove codes after exporting data.
Or use All-in-One WP Migration Files Excluder
![](/wp-content/uploads/2024/03/202344023-c799c2f34169df217099d283.png?expires=1619749051&signature=e29144df0df8b78d72a7cb7687b87fa56e10415a8bd5a0b30f233a67584d331a)
![](/wp-content/uploads/2024/03/202345115-f5e12b9ea052968a24a431c0.png?expires=1619749051&signature=deba08e8f014c5d421ff54432743334a2b62d230af76075cc17fc71e4cb7d359)
This sample excludes these directories or files from All-in-One WP Migration backup data.
/wp-contente/ai1wm-backups,/wp-content/languages,/wp-content/mu-plugins,/wp-content/plugins,/wp-content/themes,/wp-content/uploads,/wp-content/upgrades,/wp-content/object-cache.php
3. Install and activate All-in-One WP Migration
![](/wp-content/uploads/2024/03/201977022-87f400089d5283cb0c4f5f20.png?expires=1619749051&signature=ce2464f334af61c5cb300f7dc071317ae0d1b8fc6d03091b59be82d7194451c0)
4. Navigate to Export page
![](/wp-content/uploads/2024/03/201977618-441ff331b3ce91e1031d1ba3.png?expires=1619749051&signature=c153a98e997b0e9ab0de92254c961df28eb24c61d4c468c3bb1413156f05fc1d)
5. Click [Advanced Options] to configure export settings
![](/wp-content/uploads/2024/03/201977513-0e1014a1e889a29a0b6134f7.png?expires=1619749051&signature=78446b55a8450b2ba9637941a20934352dc754047c01bc15ec7641ba034f7193)
6. Check these items to export database (sql file) only.
-
[✓] Do not export spam comments
-
[✓] Do not export post revisions
-
[✓] Do not export media library (files)
-
[✓] Do not export themes (files)
-
[✓] Do not export inactive themes (files)
-
[✓] Do not export must-use plugins (files)
-
[✓] Do not export plugins (files)
-
[✓] Do not export inactive plugins (files)
-
[✓] Do not export cache (files)
-
[✓] Do not include the selected files (if available)
![](/wp-content/uploads/2024/03/201973951-acfafd4353a04b8569c1ed83.png?expires=1619749051&signature=0723f00457fe7b9451e9a6e42fddbcea144b71f6422a1135778c4030e1e54646)
7. Click [EXPORT TO] and choose [FILE]
![](/wp-content/uploads/2024/03/201976434-0aa196f7759c5ff1da7c8600.png?expires=1619749051&signature=91b694a8d4adaaa27beb65fbeca956f38a0baf5933929154da50d66398857259)
8. Click [DOWNLOAD …] and you’ve got file.
![](/wp-content/uploads/2024/03/201976466-ddb254e41e3a31d610bdd60c.png?expires=1619749051&signature=445ea91732e7156e574c776b563c7359457cf1c1f3cffa7051a5df2b433f0614)
Importing your Backup
9. Start WordPress from Shifter Headless Dashboard
https://go.getshifter.io/admin/headless
10. Activate All-in-One WP Migration on Plugins page
After logging in to your Headless WordPress site, navigate to the WordPress Plugins page activate All-in-One WP Migration plugin.
![](/wp-content/uploads/2024/03/201987237-a9e9a2fddc472114ad5c6039.png?expires=1619749051&signature=3ffec13b871e3539528ffdbcaa54d4e727c42cdd1a4a799080d506087ddc454a)
11. Navigate to [Import] under [All-in-One WP Migration] menu
![](/wp-content/uploads/2024/03/201987818-7cdba2ddf2b5b6325f650a8a.png?expires=1619749051&signature=b78778debdec13301180b29cb91b3d255cfac15a57a90d40fc35a41a5c072216)
12. Importing your Backup
![](/wp-content/uploads/2024/03/201987093-0395c778dcf2d934308f8c1d.png?expires=1619749051&signature=8b841ee870ad9d38efe29e7058dae7ab21da5a2c9105f6d19450d79cc550f5eb)
13. Click [FILE] and select backup file
![](/wp-content/uploads/2024/03/201988218-9a8b9afea403dbf8417f35ff.png?expires=1619749051&signature=6707d526346361760214323348588d05ffb88798d4fecfa77b574d321321533d)
14. Click [I HAVE ENUGH DISK SPACE] to continue
![](/wp-content/uploads/2024/03/201989161-57d654d2ef1493aedecf52f7.png?expires=1619749051&signature=ddfc898f6ec3d4688e9d522931298fffc1ee15e1b2617be39052e85aee435abd)
15. Click [PROCEED] to overwrite data.
![](/wp-content/uploads/2024/03/201989422-a7e05abf6dc13a60671b1d57.png?expires=1619749051&signature=0198dad5bf041d92699a2c6344eb7646ce9c3bbd7ae2b7cce05b8a74b4fb6096)
16. Click [FINISH]
![](/wp-content/uploads/2024/03/201989657-ec3976f4861c21b3b60260c4.png?expires=1619749051&signature=ca1d166c3f8d6c45574c316067517f536a23f13134c208282820f88a4064f4a5)
17. Logout and re-login with WordPress credentials
![](/wp-content/uploads/2024/03/201990225-8ed54e47a091aa29d1e9d2e8.png?expires=1619749051&signature=c66d845a600490c65f89c50105a32f205d62a2ee3db6e4416895e34499cdf39c)
18. Confirm data is imported
![](/wp-content/uploads/2024/03/201992910-8d7256dc9dab16a287c8cc40.png?expires=1619749051&signature=7de98879c79cc3291aa1a84a59226664202fdf2fe2dcef81c303cbb4d2a5b212)
That’s all