Drupal is a registered trademark of Dries Buytaert
Protected Pages 3.0.0 Major update available for module protected_pages (3.0.0). Commerce Core 3.3.8 Minor update available for module commerce (3.3.8). Search API HTML Element Filter 1.0.7 Minor update available for module search_api_html_element_filter (1.0.7). Layout Builder Reorder 2.0.1 Minor update available for module layout_builder_reorder (2.0.1). Ban 1.1.0 Minor update available for module ban (1.1.0). Field Formatter Range 2.0.0 Major update available for module field_formatter_range (2.0.0). Field Formatter Range 8.x-1.8 Minor update available for module field_formatter_range (8.x-1.8). Varbase Media Header 9.2.1 Minor update available for module varbase_media_header (9.2.1). Search API Solr 4.3.11 Module search_api_solr updated after 14 months of inactivity (4.3.11). Content Translation Redirect Module content_translation_redirect crossed 1,000 active installs.

AJAX Cart Update

36 sites Security covered
View on drupal.org

This module makes your Drupal Commerce shopping cart update instantly when you change item quantities or see your order total. It uses AJAX to update these parts of the cart without reloading the whole page, creating a smoother online shopping experience.

AJAX Cart Update enhances the Drupal Commerce cart by enabling real-time quantity and price updates via AJAX, creating a faster and more seamless shopping experience without page reloads.

Features

The AJAX Cart Update module improves the Drupal Commerce cart by providing dynamic AJAX-based updates for item quantities, order totals, and cart summaries without a full page reload. This ensures a faster and smoother shopping experience.

Key features:
- Real-time cart updates using either CSS selectors or a dedicated AJAX endpoint.
- Endpoint mode supports multiple custom endpoints for updating specific cart elements (e.g., prices, summaries, or cart block), with integration for Vue.js/React via the ajaxCartUpdate:endpointUpdated event.
- Supports multilingual sites with language-aware AJAX URLs.
- Flexible settings to choose the update method that best fits your site.
- Improves user experience and reduces page reloads during cart interactions.

Post-Installation

After enabling the module:
1. Go to `/admin/config/ajax-cart-update/settings`.
2. Select your preferred cart update method:
- Use CSS selectors from Views.
- Use AJAX endpoint to retrieve cart summary HTML. : For complex layouts or client-side framework integration.
3. Save the configuration.
The module automatically enhances your Commerce cart page and blocks.

Additional Requirements

- Drupal Commerce module (`commerce_cart`) must be installed and enabled.
- Views module must be installed and enabled.

Important Considerations

The AJAX Cart Update module relies on standard CSS classes and structure generated by the Commerce Cart form through the Views module.
If the Views configuration or rendered cart markup is significantly customized (e.g., changing field names, classes, or structure), it may affect the module's ability to correctly update quantities, prices, and totals.

After modifying the cart view or template, it is recommended to verify that AJAX updates continue to function correctly.

Similar projects

  • Commerce Ajax Add to Cart provides AJAX add-to-cart functionality, but doesn't update the cart form dynamically like this module.
  • Commerce Cart API offers full cart APIs but requires custom front-end work, while AJAX Cart Update works out-of-the-box with Views.

Supporting this Module

If you find this module useful, consider contributing bug reports, feature suggestions, or patches in the Drupal.org issue queue.

Community Documentation

- Complete usage instructions are available in the README file bundled with the project.

Activity

Total releases
3
First release
Sep 2025
Latest release
3 weeks ago
Releases (12 mo)
3 ▲ from 0
Maintenance
Active

Release Timeline

Releases

Version Type Release date
1.0.1 Stable Jun 24, 2026
1.0.0 Stable Nov 22, 2025
1.0.x-dev Dev Sep 24, 2025