Product selection and filtering
Default Behavior
By default, Free Downloads for WooCommerce automatically applies to all free downloadable products. However, you have several options to control which products are included or excluded.
The plugin automatically detects products that meet these criteria:
- ✅ Price is exactly 0 (zero)
- ✅ Product is marked as Downloadable
- ✅ Product is marked as Virtual
- ✅ At least one downloadable file is attached
Any product meeting all these criteria will automatically show download buttons instead of "Add to Cart".
Include Sale Products
By default, products that are on sale for free (regular price > 0, sale price = 0) are not included. You can change this behavior.
Why Exclude Sale Products?
Products on sale for free can cause issues:
- Temporary promotions: Sale ends, but download button remains
- WooCommerce download method conflicts: Especially with "Redirect" method
- Inventory management: Sale products may have stock limitations
- Unintended behavior: May not be truly "free" products
Enable Sale Products
To include products on sale for free:
- Go to WP Enhanced > Free Download Woo
- Click General in the sidebar
- Check Include paid items that are currently on sale for free
- Save changes
This is not recommended if you use the "Redirect" WooCommerce download method. It can cause conflicts with how WooCommerce handles sale products.
How It Works
When enabled:
- Products with regular price > 0 and sale price = 0 are included
- Download buttons appear during the sale period
- When sale ends, "Add to Cart" returns automatically
- All other plugin features work normally
Select Specific Products Only
Instead of automatically including all free products, you can manually select which products to include.
Enable Product Selection Mode
- Go to WP Enhanced > Free Download Woo, then click General in the sidebar
- Check Include selected products only
- Save changes
Once enabled, no products will have download buttons until you explicitly enable them.
Select Products to Include
After enabling product selection mode:
- Edit a product in WooCommerce
- Scroll to the Free Downloads settings box (right sidebar)
- Check Include this product
- Update the product
Only products with this checkbox enabled will show download buttons.
When to Use Product Selection
Use product selection mode when:
- You have many free products but only want some to bypass checkout
- You want precise control over which products use the plugin
- You're testing the plugin on specific products first
- You have free products that should still go through checkout
- You want to gradually roll out the feature
Don't use product selection mode when:
- You want all free products to have download buttons
- You have few free products (easier to manage automatically)
- You want the plugin to work automatically
Exclude Specific Products
If you want most free products to use download buttons but need to exclude a few, use product selection in reverse.
Method 1: Make Product Not Free
The simplest way to exclude a product:
- Set the price to 0.01 (or any non-zero amount)
- The plugin will ignore it
- "Add to Cart" button will appear normally
Method 2: Remove Downloadable/Virtual Flags
Another way to exclude:
- Uncheck Downloadable or Virtual
- The plugin will ignore it
- Product will behave like a normal WooCommerce product
Method 3: Use Product Selection Mode
For more control:
- Enable Include selected products only
- Manually select which products to include
- Leave excluded products unchecked
Method 4: Use Custom Code
For developers, use the somdn_is_free_download filter:
add_filter('somdn_is_free_download', function($is_free, $product_id) {
// Exclude specific product IDs
$excluded_ids = [123, 456, 789];
if (in_array($product_id, $excluded_ids)) {
return false;
}
return $is_free;
}, 10, 2);
See Advanced: Filters for more details.
Product Categories and Tags
You can use WooCommerce categories and tags to organize free downloads, but the plugin doesn't filter by category/tag directly.
Organize with Categories
Create categories for your free downloads:
- Free eBooks
- Free Templates
- Free Courses
- Free Resources
This helps customers find free downloads but doesn't affect plugin behavior.
Filter by Category (Custom Implementation)
To include/exclude products by category, use custom code:
add_filter('somdn_is_free_download', function($is_free, $product_id) {
// Only include products in "Free Downloads" category
if (has_term('free-downloads', 'product_cat', $product_id)) {
return $is_free;
}
return false;
}, 10, 2);
Product Attributes
You can use product attributes to add metadata to free downloads, but they don't affect plugin behavior directly.
Useful Attributes
- File Size: Show file size in product attributes
- File Format: PDF, ZIP, MP3, etc.
- Version: Track version numbers
- License: GPL, MIT, Creative Commons, etc.
These attributes display on the product page and help customers make informed decisions.
Bulk Product Management
Enable Plugin for Multiple Products
To enable the plugin for many products at once:
- Enable Include selected products only mode
- Use a bulk edit plugin or custom script
- Or manually edit products one by one
Disable Plugin for Multiple Products
To disable the plugin for many products:
- Bulk edit products to set price to 0.01
- Or bulk remove Downloadable/Virtual flags
- Or use custom code with product IDs
Product Visibility
The plugin respects WooCommerce product visibility settings:
- Catalog visibility: Hidden products won't show in shop
- Featured products: Work normally with the plugin
- Private products: Require login to view
- Password protected: Require password to view
All visibility settings work as expected with free downloads.
Product Stock Management
Virtual Products
Free downloads should be marked as Virtual, which:
- Removes shipping options
- Removes stock management (usually)
- Simplifies the product page
Stock Management
If you need to limit downloads using stock:
- Enable stock management on the product
- Set stock quantity
- When stock reaches 0, product becomes unavailable
- Download button is replaced with "Out of stock"
For better download limiting, use the Pro edition's Download Limits (Pro) feature instead of stock management.
Troubleshooting Product Selection
Product Not Showing Download Button
If a product should have a download button but doesn't:
- ✅ Verify price is exactly 0
- ✅ Check Downloadable is enabled
- ✅ Check Virtual is enabled
- ✅ Ensure at least one file is attached
- ✅ If using product selection mode, check Include this product is enabled
- ✅ Clear all caches
Wrong Products Showing Download Button
If products that shouldn't have download buttons do:
- ✅ Check product price (should be > 0 to exclude)
- ✅ Verify sale products setting if applicable
- ✅ Use product selection mode for precise control
- ✅ Check for custom code affecting behavior
Sale Products Not Working
If sale products don't show download buttons when enabled:
- ✅ Verify Include paid items on sale for free is checked
- ✅ Check sale price is exactly 0
- ✅ Ensure sale dates are active
- ✅ Verify product is still Downloadable and Virtual
- ✅ Clear caches
Best Practices
Product Organization
- Use categories: Organize free downloads into logical categories
- Use tags: Tag products for easy filtering
- Use attributes: Add metadata like file size, format, version
- Use featured: Highlight popular free downloads
Product Selection Strategy
Automatic Mode (Default):
- ✅ Best for most sites
- ✅ Works automatically
- ✅ Easy to maintain
- ✅ Scales well
Manual Selection Mode:
- ✅ Precise control
- ✅ Good for testing
- ✅ Gradual rollout
- ❌ More maintenance
- ❌ Easy to forget to enable
Sale Products
- Avoid if possible: Sale products can be confusing
- Use dedicated free products: Create separate products for free downloads
- Test thoroughly: If using sale products, test the entire flow
- Monitor closely: Watch for issues when sales end
Product Naming
- Be clear: "Free eBook: Getting Started" is better than "eBook 1"
- Include "Free": Helps customers identify free products
- Describe content: Make it clear what they're downloading
- Use consistent naming: Follow a naming convention
What's Next
- Display Options - Customize how downloads appear
- Settings Reference - Complete settings guide
- Advanced: Filters - Custom product filtering
- Troubleshooting - Common issues and solutions