Description
WooCommerce’s Default Search Costs You Sales
Your customers search for “blue running shoes” and get irrelevant results. They search “iphne case” with a typo and get nothing. 80% of shoppers leave after a bad search experience — and WooCommerce’s built-in search only matches exact title keywords.
Contexa fixes this. It understands what your customers mean, not just what they type.
How Contexa Is Different
- AI-Powered Semantic Search — Understands intent, not just keywords. “Laptop bag” finds “notebook carrying case” too
- Typo Tolerance — “snekers” still finds sneakers. Works across 100+ languages including Hebrew, Arabic, and English
- Instant Autocomplete — Suggestions appear as customers type, based on your store’s actual search history
- Sub-2-Second Results — Direct API with client-side rendering. No server load on your WordPress hosting
- 5 Recommendation Engines — Similar products, trending, personalized, frequently bought together, and cart-based upsells
- AJAX Add to Cart — Customers add to cart without page refresh, with quantity selectors
- 5 Visual Templates — Classic, minimal, shadow, bordered, and gradient styles in list or grid layouts
- WooCommerce Native — Automatic currency detection, stock status, and product sync
- WPML Support — Full multilingual search with language-specific content sync
- Content Search — Search blog posts, pages, and custom post types alongside products
- Order Tracking — Track which searches lead to purchases. See your search-driven revenue
- Easy Setup — Install, enter API key, sync products. Working search in under 5 minutes
Search Shortcode
Add AI search to any page:
[contexa_search layout=”list” columns=”4″ show_description=”yes” show_price=”yes” results_per_page=”12″ template=”1″]
Available options:
– placeholder – Search input placeholder text (default: “Search for products…”)
– button_text – Search button text (default: “Search”)
– layout – Display layout: list or grid (default: list)
– columns – Number of grid columns when layout=”grid” (default: 4)
– show_price – Display product prices: yes/no (default: yes)
– show_description – Display product descriptions: yes/no (default: yes)
– results_per_page – Maximum results to display (default: 12)
– template – Visual template style 1-5 (default: 1)
Template Styles:
1. Classic Grid (default) – Traditional cards with hover lift effect
2. Minimal Clean – Borderless design with subtle hover backgrounds
3. Card with Shadow – Rounded cards with elegant shadow effects
4. Modern Bordered – Bold black borders with inverted hover state
5. Colorful Gradient – Purple gradient background with white text
Examples:
`
Basic search (list layout, default template)
[contexa_search]
List layout with classic template
[contexa_search layout=”list” template=”1″]
Grid layout with 3 columns and minimal template
[contexa_search layout=”grid” columns=”3″ template=”2″]
Grid with modern bordered template, no descriptions
[contexa_search layout=”grid” template=”4″ show_description=”no”]
List with colorful gradient template and 20 results
[contexa_search layout=”list” template=”5″ results_per_page=”20″]
Custom placeholder and button text
[contexa_search placeholder=”What are you looking for?” button_text=”Find Products”]
`
Recommendations Shortcodes
Display smart product recommendations with AJAX add to cart functionality:
Similar Products (product page recommendations):
[contexa_similar product_id=”123″ title=”You May Also Like” columns=”4″ limit=”8″]
Trending Products:
[contexa_trending title=”Trending Now” columns=”4″ limit=”8″]
Personalized Recommendations (based on visitor behavior):
[contexa_personalized title=”Recommended For You” columns=”4″ limit=”8″]
Frequently Bought Together:
[contexa_frequently_together product_id=”123″ title=”Frequently Bought Together” columns=”4″ limit=”4″]
Cart-Based Recommendations:
[contexa_cart_based title=”Complete Your Purchase” columns=”4″ limit=”4″]
All recommendation shortcodes include:
– AJAX add to cart with +/- quantity selectors
– Click tracking for analytics
– Automatic stock status detection
– Responsive grid layouts
Available parameters:
– title – Section heading (optional)
– columns – Number of columns for grid display (default: 4)
– limit – Maximum number of products to display (default: 8)
– show_price – Display product prices: yes/no (default: yes)
– show_add_to_cart – Display add to cart with quantity selector: yes/no (default: yes)
Requirements
- WooCommerce 5.0 or higher
- A Contexa.co API key (free trial available)
Privacy & Data Collection
Contexa AI Search connects to external Contexa.co services to provide AI-powered search and recommendations. By using this plugin, you acknowledge that data will be sent to Contexa.co for processing.
Third-Party Service
- Service: Contexa.co – AI Search Platform
- Service URL: https://contexa.co
- API Endpoint: https://api.contexa.co
- SDK URL: https://api.contexa.co/sdk/contexa-sdk.js
- Terms of Service: https://contexa.co/terms-of-service
- Privacy Policy: https://contexa.co/privacy-policy
Data Sent to Contexa.co
Product Catalog Data (sent during sync):
* Product names, descriptions, and excerpts
* Product prices, SKUs, and categories
* Product images and URLs
* Product tags and attributes
* Blog posts and pages (if Content Sync is enabled)
Search & Interaction Data (sent during usage):
* Search queries entered by visitors
* Search results clicked by visitors
* Products added to cart
* Products removed from cart
* Completed orders (product IDs, quantities, prices)
Visitor Identification:
* Anonymous visitor ID (stored in contexa_visitor_id cookie)
* No personally identifiable information (PII) is collected
* Visitor IDs are used to track behavior across sessions for analytics
User Controls
- Tracking Consent: You can enable/disable visitor tracking in plugin settings
- Content Sync: You can choose which post types to sync (posts, pages, custom types)
- Auto Sync: You can disable automatic product synchronization
- Cookie Notice: We recommend adding a cookie consent notice to your site
External Resources Loaded
This plugin loads the Contexa search SDK JavaScript from api.contexa.co/sdk/contexa-sdk.js on all frontend pages when an API key is configured. This SDK is part of the Contexa.co service and required for AI search functionality.
Data Retention
Data sent to Contexa.co is retained according to Contexa’s privacy policy. You can request data deletion by contacting Contexa support.
Screenshots
Installation
- Upload the plugin files to
/wp-content/plugins/contexa-ai-search/directory, or install through WordPress plugins screen - Activate the plugin through the ‘Plugins’ screen in WordPress
- Get your API key from Contexa.co
- Navigate to Contexa menu in WordPress admin
- Enter your API key in the settings
- Sync your products
FAQ
-
Do I need a Contexa account?
-
Yes, you need an API key from Contexa.co. A free trial is available.
-
Will this work with my theme?
-
Yes, the plugin works with any WordPress theme that supports WooCommerce.
-
How do I add search to my site?
-
Use the shortcode
[contexa_search]on any page or post. -
Does it sync automatically?
-
Yes, you can enable automatic sync in the settings to keep products updated.
-
Can I customize the search results display?
-
Yes! The plugin includes 5 built-in templates and supports custom CSS:
Use built-in templates via shortcode:
– Template 1: Classic Grid (default)
– Template 2: Minimal Clean
– Template 3: Card with Shadow
– Template 4: Modern Bordered
– Template 5: Colorful GradientSwitch between list and grid layouts:
[contexa_search layout="list"] # Horizontal list layout
[contexa_search layout="grid" columns="3"] # Grid layout with 3 columnsAdd custom CSS to your theme:
`css/* Customize list layout */
.contexa-products-list .contexa-product-card {
padding: 20px;
border-bottom: 1px solid #eee;
}/* Customize grid layout */
.contexa-products-grid {
grid-template-columns: repeat(3, 1fr);
gap: 30px;
}/* Style product cards */
.contexa-product-card {
border-radius: 10px;
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}/* Customize quantity buttons */
.contexa-quantity-selector {
border: 2px solid #000;
}/* Hide elements */
.contexa-product-excerpt { display: none; }
`All search results use standard CSS classes – just add your styles to Appearance Customize Additional CSS.
-
How fast is the search?
-
The plugin uses direct API integration with client-side rendering for maximum performance:
– Cached results: ~200ms
– Uncached results: 1-2 seconds
– 5-minute session cache for frequently searched terms
– No server-side WordPress overhead -
Does it support autocomplete?
-
Yes! The plugin includes inline autocomplete suggestions that appear as you type, powered by the Contexa AI engine.
-
What recommendation types are available?
-
The plugin includes 5 AI-powered recommendation engines:
-
Similar Products –
[contexa_similar]- Best for: Individual product pages
- Use case: Show alternative or related products
- Where to place: Below product description, in a separate tab, or sidebar
- Example: On a phone product page, show other phone models
-
Trending Products –
[contexa_trending]- Best for: Homepage, category pages, blog sidebar
- Use case: Display what’s popular right now across your store
- Where to place: Homepage featured section, sidebar widgets
- Example: “Trending This Week” section on homepage
-
Personalized –
[contexa_personalized]- Best for: Homepage, account/dashboard pages, email campaigns
- Use case: AI-personalized recommendations based on visitor behavior
- Where to place: Homepage hero section, “Recommended For You” sections
- Example: Personalized product suggestions based on browsing history
-
Frequently Bought Together –
[contexa_frequently_together]- Best for: Individual product pages (cross-sell)
- Use case: Products commonly purchased together with current product
- Where to place: Below “Add to Cart” button or in product tabs
- Example: Phone Phone case, charger, screen protector
-
Cart-Based –
[contexa_cart_based]- Best for: Cart page, checkout page
- Use case: Upsell complementary products based on cart contents
- Where to place: Bottom of cart page, checkout sidebar
- Example: “Complete Your Purchase” section on cart page
All recommendations include AJAX add to cart with quantity selectors for seamless shopping experience.
-
-
Where should I place each recommendation shortcode?
-
Product Pages:
–[contexa_similar]– Show alternative products
–[contexa_frequently_together]– Cross-sell complementary itemsHomepage:
–[contexa_trending]– Popular products section
–[contexa_personalized]– Personalized recommendationsCart/Checkout:
–[contexa_cart_based]– Last-minute upsellsCategory/Shop Pages:
–[contexa_trending]– Trending in this categoryBlog/Content Pages:
–[contexa_trending]– Related products in sidebarYou can add shortcodes via:
– Page builders (Elementor, Gutenberg blocks)
– Theme template files (functions.php with hooks)
– Widget areas (sidebar, footer)
– Directly in product descriptions -
How do I add recommendations to product pages?
-
Method 1: Using WooCommerce hooks (recommended)
Add this to your theme’s functions.php:`php// Add “You May Also Like” below product description
add_action(‘woocommerce_after_single_product_summary’, ‘add_similar_products’, 15);
function add_similar_products() {
echo do_shortcode(‘[contexa_similar title=”You May Also Like” columns=”4″ limit=”4″]’);
}// Add “Frequently Bought Together” below Add to Cart button
add_action(‘woocommerce_after_add_to_cart_form’, ‘add_frequently_bought’, 20);
function add_frequently_bought() {
echo do_shortcode(‘[contexa_frequently_together title=”Frequently Bought Together” columns=”4″ limit=”3″]’);
}
`Method 2: Using page builders
Simply add a Shortcode widget and paste:[contexa_similar]Method 3: Product tabs
Add recommendations in a custom WooCommerce product tab for a cleaner layout. -
How do I add recommendations to the cart page?
-
Add this to your theme’s functions.php:
`phpadd_action(‘woocommerce_after_cart_table’, ‘add_cart_recommendations’);
function add_cart_recommendations() {
echo do_shortcode(‘[contexa_cart_based title=”Complete Your Purchase” columns=”4″ limit=”4″]’);
}
` -
Does this work with WPML (multilingual sites)?
-
Yes! Version 1.6.0 adds full WPML integration:
During Setup Wizard:
– Select which languages to sync (English, Spanish, French, etc.)
– See content counts filtered by selected languages
– Only sync the languages you needLanguage Filtering:
– Automatically detects post language using WPML
– Syncs only content in selected languages
– Each language is indexed separately for accurate search resultsExample:
If you have 950 total posts (305 English, 400 Spanish, 245 French) and select only English:
– Only 305 English posts will be synced
– Spanish and French posts are excluded
– Saves API quota and improves search relevanceThe wizard guides you through language selection step-by-step. You can go back and change languages at any time.
-
Does this plugin load external resources?
-
Yes, the plugin loads the Contexa search SDK from api.contexa.co as part of the Contexa.co service. This is required for the AI search functionality to work. The SDK is loaded automatically on all frontend pages when you have an API key configured.
-
What data does this plugin collect?
-
This plugin sends product data, search queries, and visitor interactions to Contexa.co to provide AI-powered search functionality. You can control tracking features in the plugin settings. See the Privacy & Data Collection section below for full details.
Reviews
There are no reviews for this plugin.
Contributors & Developers
“Contexa AI Search” is open source software. The following people have contributed to this plugin.
ContributorsTranslate “Contexa AI Search” into your language.
Interested in development?
Browse the code, check out the SVN repository, or subscribe to the development log by RSS.
Changelog
1.7.2
- Switched search, suggestions, and tracking to call Contexa API directly from frontend
- Removed WordPress AJAX proxy for search and suggestions (faster, fewer server round-trips)
- Tracking events now use fetch with keepalive instead of sendBeacon via admin-ajax.php
- Add-to-cart remains through WooCommerce AJAX for cart session handling
1.7.1
- Added suggestions dropdown list below search input with bold matching text
- Added click-to-search on suggestion selection
- Added plugin screenshots for WordPress.org listing
1.7.0
- Added variation attribute dropdowns in search results for variable products
- Added add-to-cart directly from search results using WooCommerce native AJAX
- Added add-to-cart event tracking via woocommerce_add_to_cart hook with search context
- Added inline error/success messages for add-to-cart actions
- Added platform account credentials display on settings page after onboarding
- Added credentials display on wizard completion screen
- Fixed add-to-cart for variable products — resolves matching variation from selected attributes
- Fixed duplicate add-to-cart tracking events (removed redundant handler)
- Fixed auto-sync checkbox not saving due to boolean sanitize mismatch
- Fixed tracking/logging checkboxes not saving when unchecked
- Fixed wizard not loading due to incorrect screen ID checks
- Fixed wizard registration error not showing proper message for existing emails
- Fixed product count showing 0 on sync page (sprintf %d with HTML string)
- Fixed “Sync Products Now” button linking to wrong page
- Redesigned all admin pages with consistent platform-style UI
- Redesigned settings, sync, status, and content sync pages
- Added variation dropdown CSS for list and grid layouts
- Removed .DS_Store hidden files
- Fixed all WordPress i18n translators comment warnings
- Fixed template variable prefixing for WordPress coding standards
1.6.0
- Added full WPML multi-language support with language-specific content sync
- Added interactive onboarding wizard with step-by-step setup flow
- Added language selection step in wizard for WPML-enabled sites
- Added content type selection with language-filtered counts
- Added back button navigation between wizard steps
- Fixed language filtering to properly sync only selected languages
- Fixed API data format for content-upload endpoint
- Fixed WP_Error handling in language detection
- Improved bulk sync to manually filter posts by language code
- Enhanced wizard with health score visualization and progress tracking
- Updated settings page with Contexa Dashboard login credentials display
1.5.0
- Added WordPress content support (posts, pages, custom post types)
- Enhanced bulk sync with separate endpoints for WooCommerce and content
- Improved API integration with chunking strategy for large content sets
- Added content-specific sync status tracking
1.4.0
- Performance improvements for large product catalogs
- Enhanced error handling and logging
- Updated admin UI with better sync status indicators
1.3.0
- Major performance optimization: Direct API calls with client-side rendering (7+ seconds under 2 seconds)
- Added 5 visual templates for search results (Classic, Minimal, Shadow, Bordered, Gradient)
- Added list vs grid layout toggle with configurable columns
- Added AJAX add to cart with +/- quantity selectors for both search and recommendations
- Added 5 recommendation shortcodes (similar, trending, personalized, frequently together, cart-based)
- Added automatic WooCommerce currency detection and formatting
- Added 5-minute session cache for frequently searched terms
- Fixed HTML entity rendering (em-dashes, special characters)
- Fixed product ordering to always show products first
- Fixed stock status detection for proper in-stock display
- Improved success message display for add to cart actions
- Enhanced mobile responsiveness for all layouts
- Updated recommendations to use same AJAX functionality as search results
1.2.1
- Added post_status field to content sync for proper draft/unpublished filtering
- Improved search API filtering to exclude non-published content
- Enhanced backend data consistency
- Fixed batch processing for large content libraries (50 items per batch)
1.2.0
- Added support for grouped search results by content type (results_by_type)
- Updated search API to return both flat results and grouped by post_type
- Enhanced backend API integration with new response structure
- Improved metadata with per-type result counts
1.1.0
- Added inline search suggestions (autocomplete) with ghost text
- Added support for WordPress-only sites without WooCommerce (capability fix)
- Added content search for blog posts and pages
- Improved search results grouped by content type
- Fixed capability check to use manage_options when WooCommerce is not active
1.0.0
- Initial release
- Product sync functionality
- AI search shortcode
- Smart recommendations
- Order tracking
- Content sync support
- Auto-sync capabilities





