How to Export a WordPress Theme: Complete Guide for 2025
Exporting a WordPress theme involves transferring theme files, settings, customizations, and configurations from one WordPress installation to another. Whether you're migrating to a new host, creating a backup, or moving a customized theme to another site, understanding the various export methods is essential for a smooth transition. This guide covers native WordPress export tools, plugin-based solutions, manual FTP transfer, and modern block theme export workflows.
Understanding WordPress Theme Export
Before diving into specific export methods, it's important to understand what actually constitutes a WordPress theme export. A complete theme export includes multiple components that work together to define your site's appearance and functionality.
What gets exported in a WordPress theme:
- Theme files (PHP templates, CSS stylesheets, JavaScript files)
- Template files (page.php, single.php, archive.php, index.php)
- theme.json configuration for block themes and global styling
- Customizer settings (site identity, colors, typography, layout)
- Widget configurations and sidebar assignments
- Navigation menu structures and location assignments
- Patterns and reusable blocks created in the editor
Understanding these components helps ensure nothing gets left behind during your theme transfer process. Proper theme management is a core aspect of professional WordPress development services, ensuring your site's technical foundation remains stable during any migration.
Traditional PHP-Based Themes
Traditional WordPress themes rely on PHP template files to define the structure and appearance of your site. These themes use a hierarchy of template files (like page.php, single.php, archive.php) that WordPress loads based on the type of content being displayed. Exporting traditional themes primarily involves copying the theme folder and exporting database settings that store customizer options and widget configurations.
For traditional themes, the export process centers on manual file transfer via FTP or File Manager combined with database exports for settings preservation.
Modern Block Themes
Block themes, introduced with Full Site Editing (FSE) in WordPress 6.0, use a fundamentally different approach. They rely on block-based templates defined in HTML files and a central theme.json file for global styling. WordPress 6.0+ includes native export functionality through the Site Editor, making block theme export more straightforward than traditional themes.
The MotoPress guide to block theme export documents how modern themes can leverage the Site Editor for comprehensive template and pattern export as JSON files.
Native WordPress Export Methods
WordPress includes built-in export functionality that works without requiring additional plugins. The method you use depends on whether you're working with traditional Customizer settings or modern block themes.
According to Hostinger's documentation, WordPress provides multiple native paths for theme export depending on your specific needs and WordPress version.
Exporting via WordPress Customizer
The WordPress Customizer provides a native export option for theme settings and options. This method works well for transferring site identity, colors, typography, and layout preferences between installations.
Export steps:
- Log in to your WordPress admin dashboard
- Navigate to Appearance → Customize
- Click on Tools in the Customizer sidebar
- Select Export from the available options
- Choose what to export (theme settings, all content, or media files)
- Click Export to download the .wxr or .json file
On the target site:
- Go to Appearance → Customize → Tools
- Select Import
- Upload and apply the exported file
Liquid Web's export guide notes that the native Customizer export only transfers settings and options, not the actual theme files. For complete theme transfer, combine this with FTP or File Manager download.
Site Editor Export (WordPress 6.0+ Block Themes)
For block themes running WordPress 6.0 or later, the Site Editor provides comprehensive export capabilities that capture templates, template parts, patterns, and theme.json configuration.
Export steps:
- Access the Site Editor by going to Appearance → Editor
- Click the three-dot menu in the top-right corner
- Select Export from the dropdown menu
- Choose to export templates, template parts, or both
- Download the exported .zip file containing block markup
- Export patterns separately if needed via Patterns section
On the target site, upload the exported theme files to /wp-content/themes/ and activate through the WordPress admin. The Site Editor export provides the most complete transfer for modern block themes.
Plugin-Based Export Solutions
While native tools work well for basic exports, plugins offer more comprehensive solutions for complex theme configurations, especially when transferring additional elements like widgets and custom post types.
HubSpot's WordPress tutorial recommends using plugin-based solutions when you need to transfer additional theme-related content beyond basic settings.
UpdraftPlus for Complete Backup
UpdraftPlus is one of the most popular WordPress backup plugins and provides comprehensive theme export capabilities along with complete site backup functionality.
Key features:
- Full site backup including theme files, plugins, and database
- Selective backup options to choose specific components
- Cloud storage integration (Google Drive, Dropbox, S3, etc.)
- One-click restore process on target site
- Schedule automatic backups for ongoing protection
For theme-only export, use the selective backup feature to choose only the themes folder and relevant database tables. This keeps the export file smaller while ensuring complete theme transfer.
Customizer Export/Import Plugin
The Customizer Export/Import plugin is a lightweight solution specifically designed for transferring Customizer settings between WordPress installations.
Key features:
- Exports all Customizer settings to a .json file
- Preserves site identity settings (logo, site title, icon)
- Includes navigation menu assignments in export
- Lightweight with minimal overhead
- No cloud storage required - local file transfer
This plugin is ideal when you only need to transfer settings without backing up the entire site. Combine it with FTP theme file transfer for complete theme migration.
Widget Importer & Exporter
When your theme includes custom widgets or complex sidebar configurations, the Widget Importer & Exporter plugin ensures these elements are properly transferred along with their settings.
Key features:
- Export widget configurations to .wie file format
- Preserve sidebar and widget area assignments
- Include custom widget settings and content
- Import with settings intact on target site
Hosted.com's export guide notes that widget transfer is often overlooked but critical for themes with custom widget areas or widget-based page builders.
Manual Export via FTP or File Manager
Manual export gives you complete control over the transfer process and is the most reliable method for moving theme files themselves. This approach works for both traditional and block themes.
According to Hosted.com's comprehensive overview, manual export remains the go-to method for developers who need precise control over what gets transferred. For complex migrations involving theme customization, working with experienced WordPress developers ensures all technical aspects are properly handled.
Accessing Theme Files
File transfer steps:
- Connect to your hosting account via FTP client (FileZilla, WinSCP) or File Manager in cPanel/Plesk
- Navigate to the /wp-content/themes/ directory
- Download the entire theme folder to your local machine
- Ensure all files and subdirectories are preserved exactly
- Upload the theme folder to the same location on the target site
- Activate the theme through Appearance → Themes in WordPress admin
Important: When transferring theme files, always maintain the exact folder structure and file permissions. CHMOD 644 for files and 755 for directories is standard practice for WordPress theme files.
Database Elements to Export
While theme files transfer via FTP, theme-related database entries require separate export. These include Customizer settings, widget configurations, navigation menus, and theme modifications.
Key database tables and entries:
- wp_options table - Contains theme_mods_{themename} and widget settings
- wp_terms and wp_term_relationships - Navigation menu structures
- wp_posts - Custom post types added by theme, reusable blocks
- wp_postmeta - Custom fields and theme-related metadata
Pro tip: For database export, using phpMyAdmin to export specific tables or a migration plugin like All-in-One WP Migration is often safer than manual SQL manipulation. Always backup your database before any export operation.
Exporting Block Themes and Modern Configurations
Block themes introduced with WordPress 6.0 use a new architecture based on the theme.json file and block-based templates. Exporting these themes requires understanding how these components work together.
The shift to block themes represents a fundamental change in how WordPress handles theme configuration, with JSON replacing PHP-based settings for many styling and layout decisions. Properly configured block themes can also improve your site's SEO performance by providing cleaner HTML structure and faster loading times, complementing your overall SEO strategy.
Understanding theme.json
The theme.json file serves as the central configuration hub for block themes. It defines global styles, design tokens, and block-level settings in a structured JSON format. When exporting block themes, this file is critical for maintaining consistent styling.
theme.json structure:
{
"version": 2,
"settings": {
"color": {
"palette": [...],
"gradients": [...],
"duotone": [...]
},
"typography": {
"fontFamilies": [...],
"fontSizes": [...]
},
"spacing": {
"spacingSizes": [...]
},
"layout": {
"contentSize": "650px",
"wideSize": "1200px"
}
},
"styles": {
"color": {
"background": "#ffffff",
"text": "#333333"
}
}
}
When exporting block themes, always include the complete theme.json file to preserve all design tokens and styling settings.
Exporting Templates and Template Parts
Block themes organize templates as HTML files containing block markup. Template parts (header, footer, sidebar) are stored separately and combined within templates.
Key theme directories to export:
- /templates/ - Contains template files (index.html, singular.html, archive.html, etc.)
- /parts/ - Contains template parts (header.html, footer.html, sidebar.html)
- /patterns/ - User-created patterns and reusable block combinations
- theme.json - Global styling and design token configuration
Export all these components together to ensure complete theme functionality on the target site.
Patterns Export as JSON
WordPress patterns are reusable block combinations stored as posts in the database. Exporting patterns preserves custom layouts you've created and allows them to be available in the pattern inserter on other sites.
Pattern export steps:
- In Site Editor, navigate to Patterns section
- Select user-created patterns (not theme-default patterns)
- Use export functionality or manually copy pattern HTML
- Save patterns as JSON or PHP files for re-import
- On target site, import patterns via Pattern Manager or PHP registration
Patterns export ensures your custom block combinations are available for reuse on the new installation.
Child Theme Export Considerations
Child themes are essential when you need to modify an existing parent theme while preserving the ability to update the parent. Exporting child themes requires special attention to what modifications have been made.
When to Create a Child Theme
You should create and export a child theme in these scenarios:
- Modifying parent theme template files (overriding page.php, single.php, etc.)
- Adding custom CSS that shouldn't be lost on parent update
- Adding functionality via functions.php hooks and filters
- Creating custom template files not available in parent
- Adding theme support features (post thumbnails, custom headers, etc.)
Child themes provide a safe way to customize themes while maintaining update compatibility with the parent theme.
Exporting Child Theme Modifications
When exporting a child theme, you need to capture all modifications made to the parent theme.
Files to include in export:
- style.css - Child theme stylesheet with proper template header
- functions.php - Custom functions, hooks, and filters added
- Template overrides - Any PHP files copied from parent theme
- Custom template files - New templates created for the child theme
- Additional assets - Images, fonts, JavaScript files
Example child theme style.css:
/*
Theme Name: My Custom Child Theme
Template: parent-theme-folder-name
Description: Child theme for [Parent Theme Name]
Version: 1.0.0
Author: Your Name
*/
@import url("../parent-theme-folder-name/style.css");
/* Custom styles here */
.custom-class {
property: value;
}
Preserving Custom Code Hooks
Many child theme modifications use WordPress hooks (actions and filters) to modify parent theme behavior without directly editing parent files. These hooks are typically added in functions.php and must be preserved during export.
Example hook preservation:
// Custom action hook example
add_action('wp_footer', 'my_custom_footer_script');
function my_custom_footer_script() {
echo '<script>console.log("Custom script");</script>';
}
// Custom filter example
add_filter('the_title', 'my_custom_title_prefix');
function my_custom_title_prefix($title) {
return 'Custom: ' . $title;
}
Document all hooks added to your child theme so they can be recreated on the target installation if needed.
Best Practices and Troubleshooting
Following best practices and knowing how to troubleshoot common issues ensures successful theme export and migration.
Pre-Export Checklist
Before starting any theme export, complete these essential steps:
- Test the export process on a staging site before production migration
- Document all custom modifications made to the theme
- Create a complete database backup before any export operation
- Verify theme compatibility with target WordPress version
- Check that all required plugins are available on target site
- Ensure PHP version compatibility between source and target
- Document site URL and directory structure for reference
A thorough pre-export checklist prevents issues during the actual migration process.
Common Export Issues and Solutions
Post-Export Verification
After completing your theme export and import, verify everything works correctly:
- Check all page templates render correctly across device sizes
- Verify Customizer settings are applied (logo, colors, typography)
- Test navigation menus and confirm location assignments
- Confirm widgets appear in correct sidebar areas
- Verify patterns are available in the block inserter
- Test responsive design on mobile, tablet, and desktop
- Check contact forms and interactive elements function properly
Thorough verification ensures your exported theme functions correctly on the new site.
Quick Reference: Export Method Comparison
| Method | Best For | Pros | Cons |
|---|---|---|---|
| Customizer Export | Settings only | Native tool, lightweight | No theme files transferred |
| Site Editor Export | Block themes (WP 6.0+) | Complete block export, native | Requires WP 6.0+, limited to block themes |
| UpdraftPlus | Full backup needs | Comprehensive, cloud storage | May be overkill for theme-only export |
| Customizer Export/Import Plugin | Quick settings transfer | Lightweight, focused | Limited to Customizer settings |
| FTP Download | Theme files transfer | Complete file control, works for all themes | Manual database work required |
| Widget Importer | Widget configurations | Preserves widget settings | Only handles widgets |
| Manual Database Export | Complete data transfer | Full control over what transfers | Technical complexity, risk of errors |
Sources
- Liquid Web - WordPress Theme Export - Comprehensive guide covering manual and plugin-based export methods
- Hostinger - WordPress Export Theme Tutorial - Documents three distinct export methods with step-by-step instructions
- HubSpot - Export WordPress Theme - Provides troubleshooting tips and best practices
- MotoPress - WordPress Export Theme - Detailed block theme export guide using Site Editor
- Hosted.com - Export WordPress Theme - Four ways to export including native WordPress tools