Price Based Tax
-
I have products in multiple categories in WooCommerce, and for some of these products, the tax rate is 5% if the product price is below ?1000 and 12% if the product price is above ?1000.
I am also using quantity-based discounts for these products, and I need to change the tax rate if the discounted price of the product falls below ?1k.
To address this, I have created tax classes for the different tax rates (GST 05 and GST 12), as well as GST 18 and GST 28 for products that carry an 18% tax rate regardless of the value.
By default, I have applied the GST 12 tax class to those items which I have priced above ?1k. But I am unable to find solution to change the tax rate based on the discounted price for selected producds
-
Hi @dzire2dzine
Thanks for reaching out!
I understand that you’ve created different tax rates to match the product price on your site. However, you are unable to change the tax rate based on the discounted price for selected products, correct?
As a first step, please share with us screenshots of the following settings below for us to check this further:
- General Settings (WooCommerce > Settings > General)
- Tax Settings (WooCommerce > Settings > Tax)
- Tax Classes (Standard Rate, Reduced Rate, etc)
If you don’t already have a screenshot service installed, you can try https://snipboard.io. You can share the direct link to the image as a response to this topic.
Additionally, I’d like to understand your site properly, please share your System Status Report that you can find via
WooCommerce > Status
. SelectGet system report
and thenCopy for support
. Once you’ve done that, you can paste it into your reply here.You could copy and paste your reply here or paste it via https://gist.github.com/ and send the link here.
Thanks!
Yes, I want to dynamically change it for certain products (not all), after customer use coupon code or something.
General Settings:
https://www.screencast.com/t/8Fc7ntHD
Tax Settings:
https://www.screencast.com/t/1Tl1hOhXHo
Tax class: GST 05 (and similarly all other classes are)
https://www.screencast.com/t/Eqz0dXO2S
System ReportWordPress Environment WordPress address (URL): https://ssfurnishings.com Site address (URL): https://ssfurnishings.com WC Version: 7.5.1 REST API Version: ? 7.5.1 WC Blocks Version: ? 9.6.6 Action Scheduler Version: ? 3.5.4 Log Directory Writable: ? WP Version: 6.1.1 WP Multisite: ? WP Memory Limit: 512 MB WP Debug Mode: – WP Cron: ? Language: en_US External object cache: ? Server Environment Server Info: Apache mod_bwlimited/1.4 Phusion_Passenger/6.0.17 PHP Version: 8.1.16 PHP Post Max Size: 512 MB PHP Time Limit: 300 PHP Max Input Vars: 1000 cURL Version: 7.84.0 OpenSSL/1.1.1p SUHOSIN Installed: – MySQL Version: 5.7.41 Max Upload Size: 15 MB Default Timezone is UTC: ? fsockopen/cURL: ? SoapClient: ? DOMDocument: ? GZip: ? Multibyte String: ? Remote Post: ? Remote Get: ? Database WC Database Version: 7.5.1 WC Database Prefix: **_7_ Total Database Size: 34.69MB Database Data Size: 28.29MB Database Index Size: 6.40MB **_7_woocommerce_sessions: Data: 0.76MB + Index: 0.02MB + Engine MyISAM **_7_woocommerce_api_keys: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_attribute_taxonomies: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_downloadable_product_permissions: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_order_items: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_order_itemmeta: Data: 0.01MB + Index: 0.01MB + Engine MyISAM **_7_woocommerce_tax_rates: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_7_woocommerce_tax_rate_locations: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_shipping_zones: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_shipping_zone_locations: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_shipping_zone_methods: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_payment_tokens: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_payment_tokenmeta: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woocommerce_log: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_acfw_store_credits: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_actionscheduler_actions: Data: 2.32MB + Index: 0.56MB + Engine MyISAM **_7_actionscheduler_claims: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_actionscheduler_groups: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_7_actionscheduler_logs: Data: 1.13MB + Index: 0.76MB + Engine MyISAM **_7_blc_filters: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_blc_instances: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_blc_links: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_7_blc_synch: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_commentmeta: Data: 0.03MB + Index: 0.01MB + Engine MyISAM **_7_comments: Data: 0.02MB + Index: 0.01MB + Engine MyISAM **_7_commercekit_searches: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_commercekit_swatches_cache_count: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_commercekit_waitlist: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_commercekit_wishlist: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_commercekit_wishlist_items: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_ewwwio_images: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_ewwwio_queue: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_e_events: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_e_submissions: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_e_submissions_actions_log: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_e_submissions_values: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_gla_attribute_mapping_rules: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_gla_budget_recommendations: Data: 0.11MB + Index: 0.10MB + Engine MyISAM **_7_gla_merchant_issues: Data: 0.83MB + Index: 0.02MB + Engine MyISAM **_7_gla_shipping_rates: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_gla_shipping_times: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_jetpack_waf_blocklog: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_links: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_litespeed_crawler: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_litespeed_crawler_blacklist: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_litespeed_url: Data: 0.01MB + Index: 0.02MB + Engine MyISAM **_7_litespeed_url_file: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_loginlog: Data: 0.20MB + Index: 0.04MB + Engine MyISAM **_7_options: Data: 4.46MB + Index: 0.14MB + Engine MyISAM **_7_postmeta: Data: 12.37MB + Index: 1.57MB + Engine MyISAM **_7_posts: Data: 2.52MB + Index: 0.24MB + Engine MyISAM **_7_rank_math_404_logs: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_7_rank_math_analytics_gsc: Data: 0.34MB + Index: 0.13MB + Engine MyISAM **_7_rank_math_analytics_inspections: Data: 0.26MB + Index: 0.08MB + Engine MyISAM **_7_rank_math_analytics_objects: Data: 0.19MB + Index: 0.07MB + Engine MyISAM **_7_rank_math_internal_links: Data: 0.04MB + Index: 0.01MB + Engine MyISAM **_7_rank_math_internal_meta: Data: 0.01MB + Index: 0.01MB + Engine MyISAM **_7_rank_math_redirections: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_rank_math_redirections_cache: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_shortpixel_queue: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_termmeta: Data: 0.06MB + Index: 0.05MB + Engine MyISAM **_7_terms: Data: 0.01MB + Index: 0.03MB + Engine MyISAM **_7_term_relationships: Data: 0.45MB + Index: 0.80MB + Engine MyISAM **_7_term_taxonomy: Data: 0.02MB + Index: 0.02MB + Engine MyISAM **_7_wcpdf_invoice_number: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wc_admin_notes: Data: 0.04MB + Index: 0.00MB + Engine MyISAM **_7_wc_admin_note_actions: Data: 0.02MB + Index: 0.01MB + Engine MyISAM **_7_wc_category_lookup: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wc_customer_lookup: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_7_wc_download_log: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wc_order_coupon_lookup: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wc_order_product_lookup: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_7_wc_order_stats: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_7_wc_order_tax_lookup: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wc_product_attributes_lookup: Data: 0.53MB + Index: 0.58MB + Engine MyISAM **_7_wc_product_download_directories: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wc_product_meta_lookup: Data: 0.04MB + Index: 0.04MB + Engine MyISAM **_7_wc_rate_limits: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wc_reserved_stock: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wc_tax_rate_classes: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_7_wc_webhooks: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woof_query_cache: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woof_stat_buffer: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_woof_stat_tmp: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_wt_sc_coupon_lookup: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_yith_wcwl: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_7_zbscrm_api_keys: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_admlog: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_aka: Data: 0.02MB + Index: 0.02MB + Engine InnoDB **_7_zbs_companies: Data: 0.02MB + Index: 0.06MB + Engine InnoDB **_7_zbs_contacts: Data: 0.02MB + Index: 0.02MB + Engine InnoDB **_7_zbs_customfields: Data: 0.02MB + Index: 0.02MB + Engine InnoDB **_7_zbs_dbmigration_meta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_dbmigration_posts: Data: 0.02MB + Index: 0.06MB + Engine InnoDB **_7_zbs_events: Data: 0.02MB + Index: 0.06MB + Engine InnoDB **_7_zbs_event_reminders: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_externalsources: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_forms: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_invoices: Data: 0.02MB + Index: 0.08MB + Engine InnoDB **_7_zbs_lineitems: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_logs: Data: 0.02MB + Index: 0.02MB + Engine InnoDB **_7_zbs_meta: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_notifications: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_object_links: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_quotes: Data: 0.02MB + Index: 0.08MB + Engine InnoDB **_7_zbs_quotes_templates: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_security_log: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_segments: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_segments_conditions: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_settings: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_sys_cronmanagerlogs: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_sys_email: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_sys_email_hist: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_tags: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_tags_links: Data: 0.02MB + Index: 0.03MB + Engine InnoDB **_7_zbs_tax_table: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_temphash: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_tracking: Data: 0.02MB + Index: 0.00MB + Engine InnoDB **_7_zbs_transactions: Data: 0.02MB + Index: 0.14MB + Engine InnoDB **_blogmeta: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_blogs: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_registration_log: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_signups: Data: 0.00MB + Index: 0.00MB + Engine MyISAM **_site: Data: 0.00MB + Index: 0.01MB + Engine MyISAM **_sitemeta: Data: 0.66MB + Index: 0.03MB + Engine MyISAM **_usermeta: Data: 0.17MB + Index: 0.09MB + Engine MyISAM **_users: Data: 0.02MB + Index: 0.02MB + Engine MyISAM Post Type Counts attachment: 1230 ckit_size_guide: 1 custom_css: 3 customize_changeset: 64 elementor_font: 1 elementor_library: 9 jetpack_migration: 2 mailpoet_page: 1 nav_menu_item: 245 oembed_cache: 33 page: 44 post: 5 product: 493 product_variation: 11 revision: 278 shop_coupon: 3 shop_order: 10 shop_order_refund: 1 wp_block: 1 wp_global_styles: 2 wp_navigation: 5 wpc_product_faq: 9 wpclv: 26 Security Secure connection (HTTPS): ? Hide errors from visitors: ? Active Plugins (26) Claim Gst: by Cozy Vision Technologies Pvt. Ltd. – 1.3.0 Cloudflare: by Cloudflare Inc. – 4.11.0 CommerceGurus CommerceKit: by CommerceGurus – 2.2.2 Elementor: by Elementor.com – 3.11.5 Site Kit by Google: by Google – 1.96.0 Kirki Customizer Framework: by David Vongries – 4.1.1 Secondary Title: by Kolja Nolte – 2.0.9.1 Rank Math SEO: by Rank Math – 1.0.110.2 Razorpay for WooCommerce: by Team Razorpay – 4.4.3 WooCommerce Google Analytics Integration: by WooCommerce – 1.6.2 PDF Invoices & Packing Slips for WooCommerce: by WP Overnight – 3.4.0 WooCommerce Photo Reviews Premium: by VillaTheme – 1.3.8 WooCommerce Unit Of Measure: by Bradley Davis – 3.0.3 WPC Linked Variation for WooCommerce: by WPClever – 4.0.3 WPC Price by Quantity for WooCommerce: by WPClever – 4.0.1 WPC Product FAQs for WooCommerce: by WPClever – 2.1.1 WPC Product Tabs for WooCommerce: by WPClever – 2.0.6 Akismet Anti-Spam: by Automattic – 5.1 CAPTCHA 4WP: by WP White Security – 7.1.1 Limit Login Attempts Reloaded: by Limit Login Attempts Reloaded – 2.25.13 Login Logger: by Stephen Merriman – 1.2.1 WooCommerce: by Automattic – 7.5.1 WP-DBManager: by Lester 'GaMerZ' Chan – 2.80.9 W3 Total Cache: by BoldGrid – 2.3.0 Jetpack: by Automattic – 11.9.1 Inactive Plugins (34) *************** ***************** ************* ************* Dropin Plugins (3) advanced-cache.php: advanced-cache.php maintenance.php: maintenance.php object-cache.php: object-cache.php Must Use Plugins (1) Health Check Troubleshooting Mode: by – 1.8.1 Settings API Enabled: – Force SSL: – Currency: INR (?) Currency Position: left Thousand Separator: , Decimal Separator: . Number of Decimals: 2 Taxonomies: Product Types: external (external) grouped (grouped) simple (simple) variable (variable) Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog) exclude-from-search (exclude-from-search) featured (featured) outofstock (outofstock) rated-1 (rated-1) rated-2 (rated-2) rated-3 (rated-3) rated-4 (rated-4) rated-5 (rated-5) Connected to WooCommerce.com: ? Enforce Approved Product Download Directories: ? Order datastore: WC_Order_Data_Store_CPT WC Pages Shop base: #5 - /shop/ Cart: #6 - /my-account/cart/ Checkout: #7 - /my-account/checkout/ My account: #8 - /my-account/ Terms and conditions: #112 - /policy/terms/ Theme Name: Shoptimizer Child Theme - SSF Version: 1.2.1.D2D.2 Author URL: Child Theme: ? Parent Theme Name: Shoptimizer Parent Theme Version: 2.6.5 Parent Theme Author URL: https://www.commercegurus.com/ WooCommerce Support: ? Templates Overrides: shoptimizer-child-ssf/woocommerce/single-product/product-attributes.php Admin Enabled Features: activity-panels analytics coupons customer-effort-score-tracks import-products-task experimental-fashion-sample-products shipping-smart-defaults shipping-setting-tour homescreen marketing multichannel-marketing mobile-app-banner navigation onboarding onboarding-tasks remote-inbox-notifications remote-free-extensions payment-gateway-suggestions shipping-label-banner subscriptions store-alerts transient-notices woo-mobile-welcome wc-pay-promotion wc-pay-welcome-page Disabled Features: minified-js new-product-management-experience product-variation-management settings Daily Cron: ? Next scheduled: 2023-03-27 17:59:24 +05:30 Options: ? Notes: 93 Onboarding: completed Action Scheduler Complete: 5,462 Oldest: 2023-02-24 15:50:49 +0530 Newest: 2023-03-27 15:16:51 +0530 Failed: 702 Oldest: 2022-09-15 07:51:29 +0530 Newest: 2023-03-27 13:22:53 +0530 In-progress: 1 Oldest: – Newest: – Pending: 770 Oldest: 2023-03-27 14:20:47 +0530 Newest: 2023-04-02 11:16:15 +0530 Status report information Generated at: 2023-03-27 15:17:00 +05:30 `
- This reply was modified 1 year, 8 months ago by Saket Jajodia.
Hi @dzire2dzine
Yes, I want to dynamically change it for certain products (not all), after customer use coupon code or something.
If I understand you correctly, you would like that the Tax Class of your products to be changed dynamically when a coupon code is used for an order, right?
Kindly be informed that coupons are applied to the product price?before tax is calculated. To make sure taxes are then calculated correctly due to rounding,?we need to split the discount across all items in the cart rather than remove an amount from the total. You can learn more about that here: https://woocommerce.com/document/coupon-management/#how-do-coupons-affect-tax-calculations
In your use case, changing the tax rate of a product dynamically when a coupon code is used would require customization to do.
Unfortunately, custom coding is not something we can assist with directly. However, I’ll keep this thread open for a bit to see if anyone from the community can lend a hand.
If you have any other questions related to development or custom coding, don’t hesitate to reach out to some of the great resources we have available for support. The WooCommerce community is filled with talented open-source developers, and many of them are active on the channels listed below:
- WooCommerce Developer Resources Portal
- WooCommerce Advanced Facebook group
- WooCommerce Developer Slack Channel
- Hire a WooCommerce Expert
Hope this helps!
Hi,
We haven’t heard back from you in a while, so I’m going to mark this as resolved – we’ll be here if and/or when you are ready to continue.
Thanks.
- The topic ‘Price Based Tax’ is closed to new replies.