Import & Export
5 min read
Updated Mar 3, 2026
Bulk import and export packages in WordPress Download Manager. Access from Downloads > Import & Export in your WordPress admin.
Overview
The Import & Export feature allows you to:
- Migrate packages between WordPress sites
- Bulk create packages from CSV files
- Import files from server directories
- Export packages for backup
- Share package configurations
Export Packages
Export Options
| Format | Best For |
|---|---|
| CSV | Spreadsheet editing, bulk updates |
| JSON | Full data preservation, API use |
| XML | WordPress import compatibility |
What Gets Exported
| Data | CSV | JSON | XML |
|---|---|---|---|
| Title | Yes | Yes | Yes |
| Files & URLs | Yes | Yes | Yes |
| Categories & Tags | Yes | Yes | Yes |
| Settings | Partial | Full | Full |
| Meta Data | Partial | Full | Full |
| Images | URL only | URL only | URL only |
| Statistics | No | Yes | Yes |
How to Export
- Go to Downloads > Import & Export
- Choose export format
- Click Create Export File button
- Download the file
Batch Export
For large numbers of packages:
- Export runs in batches
- Progress bar shows status
- File downloads when complete
- Large exports may take time
Import from CSV
CSV Format
Required columns:
| Column | Description | Example |
|---|---|---|
| title | Package title | My Download |
Optional columns:
| Column | Description | Example |
|---|---|---|
| description | Package description | Full description… |
| post_status | Publish status | publish, draft |
| url_slug | URL permalink | my-download |
| files | Attached files (pipe-separated) | file1.zip, file2.pdf |
| file_titles | File display names | File One, File Two |
| category | Category names | Category1,Category2 |
| tags | Tag names | Tag1,Tag2,Tag3 |
| access | Allowed roles | administrator,editor |
| version | Package version | 1.0.0 |
| template | Link template | default |
| page_template | Page template | default |
| password_lock | Enable password | 0 or 1 |
| password | Lock password | mypassword |
| email_lock | Enable email lock | 0 or 1 |
| base_price | Product price | 29.99 |
| icon | Icon URL | https://… |
Sample CSV
title,description,files,category,access,version "My First Package","A great download","/uploads/file1.zip","Software","subscriber",1.0.0 "Another Package","Description here","/uploads/file2.pdf|/uploads/bonus.zip","Documents","all",2.0.0
Import Steps
- Prepare your CSV file
- Go to Downloads > Import & Export
- Click the Select CSV File tab
- Select and upload your file
- Review import results
Column Mapping
If your CSV uses different column names:
- After upload, the mapping screen appears
- Match your columns to WPDM fields
- Skip columns you don’t want to import
- Save mapping for future imports
Import Options
| Option | Description | Default |
|---|---|---|
| Update Existing | Update if title matches | Disabled |
| Create Categories | Auto-create missing categories | Enabled |
| Create Tags | Auto-create missing tags | Enabled |
| Set Status | Override status for all | Use CSV value |
| Author | Assign all to author | Current user |
Batch Import
Large imports process in batches:
| Setting | Description | Default |
|---|---|---|
| Batch Size | Rows per batch | 10 |
| Delay | Seconds between batches | 0 |
Progress shows:
- Current row
- Success count
- Error count
- Time elapsed
Import from Directory
Directory Import
Import files directly from a server directory:
- Go to Downloads > Import & Export
- Select directory from the Select Directory list
- Browse or enter directory path
- Select files to import
- Configure import options
- Click Import Selected Files
File Browser
The file browser shows:
| Column | Description |
|---|---|
| Filename | File name |
| Size | File size |
| Type | File extension |
| Modified | Last modified date |
Import Options
| Option | Description |
|---|---|
| Create Package Per File | Each file = one package |
| Group Files | Multiple files = one package |
| Use Filename as Title | File name becomes title |
| Move vs Copy | Move file or copy it |
| Target Directory | Where to store files |
Supported Locations
| Location | Path |
|---|---|
| Uploads | /wp-content/uploads/ |
| WPDM Files | /wp-content/uploads/wpdm-files/ |
| Custom | Any accessible directory |
Import from JSON/XML
JSON Import
- Go to Import tab
- Select JSON file
- Review package data
- Click “Import All” or select specific packages
- Confirm import
XML Import
- Go to Import tab
- Select XML file
- WordPress-compatible XML supported
- Review and import
Handling Errors
Common Import Errors
| Error | Cause | Solution |
|---|---|---|
| File not found | Invalid file path | Check file exists |
| Invalid CSV | Malformed CSV | Check formatting |
| Missing title | No title column | Add title column |
| Permission denied | File not readable | Check permissions |
| Memory limit | File too large | Increase PHP memory |
Error Log
After import, review the error log:
- Check error log file
- See row-by-row issues
- Download error report
- Fix issues and re-import
Rollback
If import goes wrong:
- Note imported package IDs
- Go to Downloads > All Downloads
- Filter by import date
- Bulk delete if needed
Migration Between Sites
Full Migration
- Source site: Export all packages (JSON recommended)
- Export media: Note all file URLs
- Target site: Import JSON file
- Transfer files: Upload files to target
- Update URLs: Fix file paths if needed
Partial Migration
- Export specific categories
- Export specific packages
- Import to target
- Reassign categories if needed
Post-Migration Checklist
| Task | Description |
|---|---|
| Verify counts | Same number imported |
| Check files | Files accessible |
| Test downloads | Downloads work |
| Check categories | Properly assigned |
| Review settings | Package settings correct |
Automation
WP-CLI Commands
# Export packages wp wpdm export --format=csv --output=/path/to/export.csv # Import from CSV wp wpdm import /path/to/import.csv --create-categories # Import from directory wp wpdm import-dir /path/to/files --create-packages
Scheduled Exports
Set up automatic exports:
- Go to Cron Jobs Settings
- Create new job
- Hook:
wpdm_scheduled_export - Set schedule
- Configure export path
Tips
- Always backup before bulk imports
- Test with small CSV first
- Use JSON for complete data preservation
- Check file paths in CSV are correct
- Match column names exactly for smooth import
- Review import log for any errors
- Keep export files for disaster recovery