Contexa AI Search

Plugin Banner

Contexa AI Search

by contexa

Download
Description

Contexa AI Search brings powerful AI-driven search and product recommendations to your WooCommerce store. Enhance customer experience with intelligent product discovery and blazing-fast search results.

Key Features

  • AI-Powered Search: Natural language product search with autocomplete suggestions
  • Lightning Fast Performance: Direct API integration with client-side rendering (under 2 seconds)
  • Smart Recommendations: Personalized product suggestions
  • Flexible Layouts: Choose between list or grid display with 5 customizable templates
  • Easy Integration: Simple shortcodes, no coding required
  • Auto Sync: Keep products updated automatically
  • Product Management: Sync, preview, and export products with batch processing
  • Order Tracking: Track conversions and customer behavior
  • Content Sync: Sync blog posts, pages, and custom post types for comprehensive search
  • AJAX Add to Cart: Add products to cart without page refresh with quantity selectors
  • Multi-Currency Support: Automatic currency detection from WooCommerce settings
  • Customizable: 5 visual templates, filters, and actions for complete control
  • WPML Multi-Language Support: Full integration with WPML for language-specific content sync
  • Onboarding Wizard: Step-by-step setup wizard with language and content type selection
  • Language Filtering: Sync only the languages you need with WPML integration

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.

  1. Upload the plugin files to /wp-content/plugins/contexa-ai-search/ directory, or install through WordPress plugins screen
  2. Activate the plugin through the ‘Plugins’ screen in WordPress
  3. Get your API key from Contexa.co
  4. Navigate to Contexa menu in WordPress admin
  5. Enter your API key in the settings
  6. Sync your products
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 Gradient

Switch between list and grid layouts:
[contexa_search layout="list"] # Horizontal list layout
[contexa_search layout="grid" columns="3"] # Grid layout with 3 columns

Add 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:

  1. 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
  2. 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
  3. 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
  4. 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
  5. 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 items

Homepage:
[contexa_trending] – Popular products section
[contexa_personalized] – Personalized recommendations

Cart/Checkout:
[contexa_cart_based] – Last-minute upsells

Category/Shop Pages:
[contexa_trending] – Trending in this category

Blog/Content Pages:
[contexa_trending] – Related products in sidebar

You 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:

`php

add_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 need

Language Filtering:
– Automatically detects post language using WPML
– Syncs only content in selected languages
– Each language is indexed separately for accurate search results

Example:
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 relevance

The 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.

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
Back to top