A comprehensive WordPress plugin that seamlessly integrates InstaWP's site creation and management capabilities with your WordPress website and WooCommerce store.
- Direct Site Creation - https://www.youtube.com/watch?v=XrmSijeVNSc
- With Trial Site - https://www.youtube.com/watch?v=in04cyMqvbQ
The InstaWP Integration plugin enables you to:
- Create WordPress sites instantly using InstaWP snapshots
- Integrate site creation with WooCommerce products and orders
- Manage InstaWP sites directly from your WordPress admin
- Provide customers with easy access to their created sites
- Use shortcodes for standalone site creation forms
- Add InstaWP snapshots and plans to WooCommerce products
- Automatically create sites when orders are completed
- Customer access to sites via My Account dashboard
- Email notifications with site details and login credentials
- Support for both permanent and temporary sites
- Centralized settings with tabbed interface
- View and manage all InstaWP snapshots and plans
- Test order creation for development and testing
- Debug mode with comprehensive logging
- Sites management with quick actions
[iwp_site_creator]shortcode for standalone site creation- Customizable parameters for pre-filled forms
- Real-time status tracking during site creation
- Mobile-responsive design
- Site plan upgrades via URL parameters
- Custom domain mapping for created sites
- Magic login integration for seamless admin access
- Demo site storage and automatic reconciliation to orders
- Go Live page smart redirects for paid users
- HPOS (High Performance Order Storage) compatibility
- Comprehensive error handling and logging
- Download the plugin files
- Upload to your WordPress
/wp-content/plugins/directory - Activate the plugin through the 'Plugins' menu in WordPress
- Go to InstaWP → Settings to configure your API key
-
Get Your API Key
- Visit InstaWP API Tokens
- Generate a new API token
- Copy the token
-
Configure Plugin
- Navigate to InstaWP → Settings in WordPress admin
- Enter your API key in the General Settings tab
- Enable desired integration options
- Click "Refresh Snapshots" and "Refresh Plans" to load your data
-
Configure Products (WooCommerce)
- Edit any WooCommerce product
- Go to the InstaWP tab
- Select a snapshot and plan for the product
- Choose site expiry settings (permanent/temporary)
- Save the product
- Edit a WooCommerce product
- Click the InstaWP tab
- Select an InstaWP snapshot from the dropdown
- Choose a plan (optional)
- Configure site expiry:
- Permanent: Sites remain active indefinitely
- Temporary: Sites expire after specified hours (1-8760)
- Save the product
- Customers purchase products with InstaWP integration
- Sites are automatically created when orders are completed
- Customers receive email notifications with:
- Site URL and admin login credentials
- Magic login links (when available)
- Direct access to their WordPress dashboard
- Customers can view all their sites in My Account → Orders
[iwp_site_creator snapshot_slug="your-snapshot-slug"]
// Pre-filled form
[iwp_site_creator snapshot_slug="ecommerce-store" email="customer@example.com" name="My Store"]
// Temporary site (24 hours)
[iwp_site_creator snapshot_slug="demo-site" expiry_hours="24"]
// Demo environment
[iwp_site_creator snapshot_slug="wordpress-blog" email="demo@test.com" name="Demo Site" expiry_hours="48"]
snapshot_slug(required): The InstaWP snapshot to useemail(optional): Pre-fill the email fieldname(optional): Pre-fill the site name fieldexpiry_hours(optional): Hours until site expiressandbox(optional): Set to "true" for shared/sandbox sites
Enable customers to upgrade existing sites instead of creating new ones:
- Enable Feature: Check "Use site_id Parameter" in plugin settings
- Customer Workflow:
- Customer visits:
yoursite.com/shop/?site_id=123 - Plugin enters "upgrade mode"
- Customer purchases plan-enabled product
- Existing site is upgraded instead of creating new site
- Customer visits:
The plugin supports InstaWP team functionality, allowing you to work with multiple teams and filter data accordingly.
- Navigate to InstaWP → Settings → InstaWP Data
- Use the team dropdown to select a specific team
- By default, "User's Logged In Team" is selected (no team filter)
- When you select a team, all snapshots and plans will be filtered to show only that team's data
- Automatic Filtering: Snapshots and plans automatically filtered by selected team
- Team-Specific Caching: Each team's data is cached separately for better performance
- API Parameter: Selected team ID is automatically added to API calls as
?team_id={id} - Persistent Selection: Your team choice is saved and remembered across sessions
The plugin automatically stores demo sites created via the shortcode and reconciles them to customer orders upon payment.
1. Demo Site Creation
- Customer creates a site using
[iwp_site_creator]shortcode - Site is stored in database with
site_type='demo' - Customer's email is stored for future reconciliation
- Works for both logged-in users and guests
2. Automatic Reconciliation
- When a customer makes a purchase, the plugin searches for demo sites matching their email
- All matching demo sites are automatically converted to paid sites
- Demo sites are associated with the order and customer account
- Demo helper plugin is automatically disabled
- Order note is added documenting the conversion
3. Frontend Display
- Reconciled sites display with a "Converted from Demo" badge
- Sites appear in customer's order details and My Account page
- Full access to site credentials and admin login
4. Go Live Page Redirect
- Users without paid sites can access Go Live pages normally
- Users with paid sites are automatically redirected to My Account dashboard
- Prevents confusion for customers who already have active sites
✅ No Data Loss: Demo sites are never lost, always tied to customer accounts ✅ Seamless Experience: Customers continue using the same site after payment ✅ Multiple Sites: All demo sites with matching email are converted ✅ Email Matching: Works even if customer creates account after demo ✅ Zero Config: Automatic - no setup required
Demo sites are stored with the following information:
- Site ID and URL
- Admin credentials (username/password)
- Customer email (for reconciliation)
- Site status and type (
demoorpaid) - Creation timestamp and expiry settings
- Full API response for debugging
- View all created sites in InstaWP → Sites
- Quick actions: Visit Site, Magic Login, Delete
- Real-time status updates
- Order references and customer information
- Enable debug mode for detailed logging
- Create test orders with real users
- Monitor API calls and responses
- Cache management for snapshots and plans
The plugin integrates with the following InstaWP API endpoints:
| Endpoint | Method | Purpose | Timeout |
|---|---|---|---|
/teams |
GET | Fetch user teams | 60s |
/snapshots |
GET | Fetch available snapshots | 60s |
/get-plans?product_type=sites |
GET | Fetch hosting plans | 60s |
/sites/template |
POST | Create site from snapshot | 60s |
/tasks/{task_id}/status |
GET | Check site creation progress | 60s |
/sites/{site_id} |
GET | Get site details | 60s |
/sites/{site_id}/upgrade-plan |
POST | Upgrade site plan | 60s |
/sites/{site_id} |
PATCH | Update site configuration | 60s |
/sites/{site_id} |
DELETE | Delete site | 60s |
| Endpoint | Method | Purpose | API Version |
|---|---|---|---|
/site/add-domain/{site_id} |
POST | Map custom domain to site | v1 |
- Authentication: Bearer token with API key
- Content-Type: JSON requests and responses
- Timeout: 60 seconds for all requests
- Caching: Snapshots (15 min), Plans (1 hour)
- Error Handling: Comprehensive WordPress error integration
- Logging: Detailed debug logging with sanitized responses
The plugin includes built-in rate limiting and request throttling to prevent API abuse and ensure optimal performance.
- Enable Integration: Master toggle for the plugin
- Auto-Create Sites: Automatically create sites when orders complete
- Use site_id Parameter: Enable site upgrade functionality
- Team Selection: Choose which team's data to view and manage
- Snapshots: View and refresh available snapshots (filtered by selected team)
- Plans: View and refresh available hosting plans (filtered by selected team)
- API Status: Connection status and cache information
- Debug Mode: Enable detailed logging
- Log Level: Set logging verbosity (Debug, Info, Warning, Error)
- Test Orders: Create test orders for development
- Check user permissions (administrator required)
- Verify WordPress nonce functionality
- Check for plugin conflicts
- Verify API key is correct and active
- Check internet connectivity
- Clear plugin cache (refresh buttons)
- Enable debug mode to view detailed error logs
- Verify selected snapshot exists in your InstaWP account
- Check API key permissions
- Review WooCommerce order status (must be completed/processing)
- Check debug logs for specific error messages
- Ensure WooCommerce is active
- Verify user has
edit_productscapability - Check for theme/plugin conflicts
- Clear WordPress cache
Enable debug mode to troubleshoot issues:
- Go to InstaWP → Settings → Testing & Development
- Enable "Debug Mode"
- Set log level to "Debug"
- Reproduce the issue
- Check WordPress debug logs or contact support with log details
- Use Caching: Plugin caches API responses automatically
- Optimize Settings: Disable unnecessary features for better performance
- Monitor Logs: Regular log review helps identify issues early
- API Limits: Respect InstaWP API rate limits
- Check Documentation: Review this README and plugin settings
- Debug Logs: Enable debug mode and check WordPress error logs
- Test Environment: Use test order functionality to isolate issues
- Community Support: WordPress community forums
- InstaWP Support: For API-related issues, contact InstaWP support
When reporting issues, please include:
- WordPress version
- WooCommerce version (if applicable)
- Plugin version
- Debug logs (with sensitive information removed)
- Steps to reproduce the issue
- Expected vs actual behavior
- Minimum Version: WordPress 5.0+
- Recommended: WordPress 6.0+
- PHP Version: 7.4+
- Memory Limit: 128MB+ recommended
- Minimum Version: WooCommerce 5.0+
- HPOS Support: Compatible with High Performance Order Storage
- Tested Up To: WooCommerce 8.0+
- cURL: For API communications
- JSON: For API request/response handling
- Sessions: For site upgrade functionality
- WordPress Cron: For background processing
This plugin is licensed under the GPL v2 or later.
- NEW: Demo Site Storage & Reconciliation System
- Automatically stores demo sites created via shortcode in database
- Site_id-based reconciliation for upgraded demo sites (priority: session → order meta → email)
- Email-based reconciliation: converts demo sites to paid when customer purchases
- Supports multiple demo sites per customer
- Works for both logged-in users and guests
- "Converted from Demo" badge displays in order details
- NEW: Admin Filters & Search
- Status view links (All, Active, Creating, Failed, Expired) with counts
- Source filter dropdown (WooCommerce, Shortcode, etc.)
- Search box for URL, username, user, site_id, order_id
- Filters work together and maintain state across pagination
- NEW: Expiry Status Tracking
- Real-time expiry calculation without API calls
- "Expired" status badge for sites past expiry time
- Time remaining display (hours/minutes) for active temporary sites
- Visual warnings when <1 hour remaining
- NEW: Go Live Page Smart Redirect
- Automatically redirects users with paid sites to My Account
- Prevents confusion for customers who already purchased
- Configurable page slugs (
go-live,launch-your-demo-site)
- NEW: Automatic Database Migration System
- Version-aware database updates
- Automatic migration on plugin update
- Manual migration page:
/wp-admin/admin.php?page=iwp-migrate-db - Admin notices when updates are available
- Safe and idempotent migrations
- Database Schema Updates
- Added
site_typecolumn (VARCHAR 50) towp_iwp_sitestable - Added
idx_site_typeindex for query performance - Existing sites automatically default to
site_type='paid'
- Added
- FIXED: Shortcode Site Creation
- Database now updates after non-pool site task completion
- Added
update_demo_site_details()to store credentials when polling completes - Sites properly store full details (URLs, credentials, s_hash) after task finishes
- FIXED: Order Sites Display
get_order_sites()prioritizes database records over stale order meta- Plan upgrades now show updated values instead of old site data
- FIXED: Expiry Hours Management
- Expiry hours cleared on demo→paid conversion
- Original expiry preserved in source_data for history
- Prevents accidentally expiring paid sites converted from demos
- API Enhancements
- Added demo site query methods in Sites Model
- Added
get_demo_sites_by_email()for reconciliation - Added
get_demo_sites_by_user()for user queries - Added
mark_expired_demos()for cleanup
- Code Quality
- Applied DRY principle with helper methods for badge generation
- Moved inline CSS to stylesheet
- Consistent data structure across database and order meta sites
- Frontend Improvements
- Demo badge styling (orange with white text)
- Better order details display for reconciled sites
- Improved mobile responsiveness
- Fixed WooCommerce Subscription error reported by Fixrunner
- Complete refactor from WooCommerce-specific to generic WordPress integration
- New simplified admin interface with tabbed settings
- Enhanced shortcode functionality with real-time status tracking
- Site upgrade functionality via URL parameters
- Magic login integration
- Custom domain mapping support
- HPOS compatibility
- Comprehensive error handling and logging
- Mobile-responsive design
- API timeout increased to 60 seconds
- Fixed wpdb::prepare array error: Resolved database error when updating site records with array values
- Fixed frontend credential display: Username and password now display correctly in customer-facing interfaces
- Improved site information positioning: Site details now appear right after order table instead of at page bottom
- Enhanced WooCommerce Subscriptions support: Fixed argument count errors in subscription hooks
- Added demo helper auto-disable: Automatically disables demo plugin when sites upgrade to paid plans
- Team management improvements: Better team filtering and caching for multi-team environments
- UI enhancements: Fixed radio button spacing and mobile responsiveness in product settings
- Map domain functionality: Restored missing domain mapping features on order pages
Need Help? Check the plugin settings page for more detailed documentation and examples, or refer to the troubleshooting section above.