WooCommerce developer in Valencia

WooCommerce for businesses in Valencia, delivered remotely by one developer.

WooCommerce developer

My place in the WordPress community

  • I have had a wordpress.org account since 2006.
  • I contributed to WordPress core for versions 7.0 and 7.1.
  • I maintain 30 plugins on wordpress.org.
  • I organise and speak at WordCamps.
  • I have attended every WordCamp Europe from 2017 to 2026.

My WordPress.org profile

#WooCommerce developer in Valencia for sale prices, labels and scheduled sales

A crossed-out price in a Spanish shop is regulated. Ley 7/1996, de 15 de enero, de Ordenación del Comercio Minorista, says what the old price on a discounted item has to be and how sales may be named. The consolidated text on boe.es shows art. 20 in the wording in force since 28 May 2022. This page covers what that means for a WooCommerce shop that sells to Spain, and what the sale price fields, labels and schedules have to do.

I am Mariusz Szatkowski, a WordPress and WooCommerce developer from Gdynia. I work alone, remotely and in writing, and I have worked with WordPress since 2006. The storefront layout is mine to design, or I implement the one you bring. Whether a given offer is lawful is for you and your adviser. My part is making the shop able to show the right figures and keep the evidence.

Interior of the Mercado de Colon in Valencia

Photo: Diego Delso, CC BY-SA 3.0, Wikimedia Commons.

#Which Spanish law governs sales and sale prices?

Ley 7/1996 groups what it calls sales promotion activities in art. 18: sales en rebajas, en oferta o promoción, de saldos, en liquidación, con obsequio and offers of direct sale. Three rules in that article shape a shop build:

  • The names may only be used for sales that match the legal concept of each. Using them for other sales is prohibited (art. 18(2)).
  • Using a name that does not fit the regulation is treated as unfair when the conditions of art. 5 of the unfair competition law are met (art. 18(3)).
  • Several promotion activities may run in one establishment at the same time, except liquidations, as long as they are kept apart and the information duties are respected (art. 18(4)).

So the words in a badge or banner are not free text. “Rebajas”, “saldos” and “liquidación” each have a legal meaning, and a shop that uses them loosely is covered by the article.

#What is the 30-day previous price?

Art. 20(1) says that whenever articles are offered at a reduced price, the previous price must appear clearly on each of them next to the reduced price, unless the article is put on sale for the first time. The previous price is the lowest one applied to identical products in the preceding thirty days. Prices applied to identical products close to expiry or best-before date to reduce food waste are not taken into account.

The BOE notes that art. 20(1) was changed by art. 85 of Real Decreto-ley 24/2021, de 2 de noviembre, with effect from 28 May 2022. Art. 20(2) adds that using sales promotion activities cannot be made conditional on a minimum or maximum percentage reduction.

Two details matter for the build:

  1. The reference is the lowest price of the last thirty days, not the usual price and not the price before the latest increase.
  2. The rule is stated per article. Whether the variants of a product count as identical products is a legal question. The build can record history per variation, so either answer can be applied later without rebuilding.

#What does WooCommerce store for a sale price?

In WooCommerce core, a product has a regular price, an optional sale price and optional sale start and end dates. The product class decides is_on_sale() like this: a sale price must exist, the regular price must be higher than it, the start date must not lie in the future and the end date must not have passed. When a product is on sale, get_price_html() builds the output from wc_format_sale_price(), with the regular price as the struck-through figure and the current price next to it.

Nothing in that logic knows what the product cost over the last thirty days. The struck-through number is whatever sits in the regular price field. That is correct when the regular price was stable for at least thirty days and no earlier sale ran inside that window. It is not automatically correct in these cases:

  • The regular price was raised shortly before the sale.
  • A first sale ended and a second one starts within thirty days, so the lowest recent price is the first sale price.
  • A supplier import or a bulk edit changed prices several times.

The fix is a small price history, not a larger discount field. The build records every price change per product and variation with a timestamp, computes the lowest figure of the last thirty days when a sale is shown, and prints that figure as the previous price. Where a product is new, the history has no earlier entry and the display follows the first-time exception of art. 20(1). The rule about food close to expiry is an input you decide: the build can mark such price changes so they stay out of the calculation.

#How do scheduled sales work, and what can go wrong?

WooCommerce can start and end sales by date. In wc-product-functions.php the function wc_scheduled_sales() is attached to the action woocommerce_scheduled_sales. It collects the products whose sales are due to start, processes them, and does the same for the ones due to end. Around each step it fires wc_before_products_starting_sales and wc_after_products_starting_sales, plus the matching pair for ending sales, and it deletes the wc_products_onsale transient.

For a Spanish shop that gives three jobs:

  • Write the history on the hooks. The after-start and after-end actions are the place to record that a sale started or ended and what the price was.
  • Clear the cache. is_on_sale() compares the dates with the current time when it is called, but a full-page cache stores finished HTML. A cached page can keep showing the old price after a sale ended. The build purges the affected product, category and home pages when the sale state changes.
  • Plan for batches. A sale that applies to a few hundred products at once should be a tested import with a rollback, not a manual edit on the production shop.

#What must sale labels and listings show?

Several articles of Ley 7/1996 turn into template rules:

ArticleRule in the BOE textWhat the template does
19(1)Advertisements for sales state their duration and any special rulesThe banner and the product page show the end date and conditions from the same schedule
19(2)If special offers do not cover at least half of the articles, the practice cannot be advertised as a general measureA site-wide banner is only available when the share of discounted products reaches half; otherwise it names the categories
20(1)The previous price appears with the reduced priceThe history figure from the section above is printed next to the current price
21Normal-price and reduced-price articles are separated so nobody can mistake one for the other, distinguishing rebajas, saldos, liquidaciones, promociones and obsequiosListings carry a clear label per promotion type and discounted items are not mixed with full-price ones without a visible difference
18(2)The names only for sales that fit the legal conceptThe label list is a fixed set tied to a promotion type, not a free text field

WooCommerce prints its default badge through the woocommerce_sale_flash filter, which wraps the word “Sale!” in a span with the class onsale. The build replaces that output with the label of the promotion type and keeps the wording in one place, so a change of wording happens once.

The check for 19(2) is simple to automate. A report counts the products on sale against the catalogue and warns when a banner claims more than the data supports.

#When is it a sale in rebajas, and when a promotion?

Art. 24 defines the venta en rebajas: articles offered, in the same establishment where the activity is usually carried out, at a price lower than the one set before the sale. Art. 24(2) excludes products that were not previously on sale at the ordinary price, and damaged products or ones bought to be sold cheaper than the ordinary price. Art. 25 says rebajas may take place in the seasonal periods of greatest commercial interest at each retailer’s discretion, and that the length of each period is decided freely by each retailer. Art. 26(2) forbids offering damaged articles as reduced.

Art. 27 covers ventas en promoción o en oferta: sales not specifically covered by another chapter, made at a lower price or on more favourable conditions than usual, to boost the sale of certain products or the development of one or more shops. Art. 27(3) applies arts. 33 and 34 to them. Two clauses of the original articles, art. 26(1) and art. 27(2), were annulled by the Tribunal Constitucional in Sentencia 18/2016, according to the BOE notes, so the consolidated text no longer contains them.

For the build this means every discount carries a type chosen from a short list. Products added to the catalogue inside a sale window are flagged, because art. 24(2) and the first-time exception of art. 20(1) both depend on whether the product was sold at an ordinary price earlier. A product with no earlier ordinary price does not get the rebajas label.

#What does the build contain?

The list below is my translation of the articles into shop tasks, not a legal opinion.

  1. Price history table. Product or variation ID, price, price type, start and end time, source of the change (manual, import, schedule).
  2. Previous price service. One function returns the lowest price of the last thirty days for a product and is used by templates, feeds and the REST output alike.
  3. Promotion type field. A fixed list: rebajas, oferta o promoción, saldos, liquidación, obsequio. Each type has its own label text in Spanish, Valencian if you offer it, and English.
  4. Schedule with an end date. A sale without a visible end date cannot publish a banner.
  5. Cache purge on the start and end hooks.
  6. Coverage report. Products on sale against the catalogue, for the half-of-articles rule.
  7. Audit export. A CSV that shows, per product and date, which price was displayed and which previous price was shown beside it.

Payment, tax and shipping are out of scope on this page. For the wider WooCommerce work I do, see the WooCommerce developer page.

#Checklist for a Spanish WooCommerce sale

  • Decide which promotion types you use and use the legal names only for sales that fit them.
  • Keep a dated record of every price change per product and variation.
  • Show the lowest price of the last thirty days next to the reduced price, except for first-time products.
  • Do not set a minimum or maximum discount percentage as a condition for using a promotion.
  • Show the duration and special rules on every announcement of a sale.
  • Name the categories when fewer than half of the articles are included.
  • Separate reduced and full-price articles visibly in listings and the cart.
  • Keep damaged articles out of the rebajas label.
  • Purge the page cache when a sale starts or ends.
  • Test a scheduled sale on staging with the real start and end times before it goes live.

#How does a sale price build run?

  1. You send the shop address, how prices are managed today (manual, supplier import, ERP), the promotion types you use, the languages of the shop, your deadline and the plugins in use. On working days you get my email answer within 24 hours.
  2. I write down the scope and my assumptions, with questions: where price changes come from, how variants are handled, which promotion types exist, who approves a sale.
  3. I build on a staging copy, and you run test sales with scheduled start and end times.
  4. Once you accept in writing, the shop goes live with the new price logic. A maintenance plan can keep the shop updated and recheck prices, labels and the cache purge after each update.

I need admin access to WordPress and hosting, the supplier or ERP price feed if there is one, and the list of promotion types you plan to use.

#Send me your shop

If your Valencia shop runs sales, scheduled promotions or crossed-out prices, send me the shop address, how your prices are managed, the promotion types you use, your deadline and your plugins through the contact form. My first written estimate for sale price work costs you nothing.

Need this service: WooCommerce developer in Valencia?

Describe your project by e-mail. I reply within 24 hours.

Describe your project

Latest WooCommerce developer articles

Nov 20, 2026

Lemon Squeezy shutting down: best alternatives

Lemon Squeezy stops processing payments on 31 March 2027. What changes when moving to Stripe Managed Payments (no license keys, digital delivery, storefront, affiliates, or PayPal subscriptions) and how to migrate to WooCommerce.

Nov 20, 2026

Countdown timers in an online shop: when are they illegal?

A fake countdown timer or a false 'only 2 left' message is on the list of practices that are always unfair in Ireland and the UK. What the Consumer Protection Act 2007 and the DMCC Act 2024 say, what the CMA did about Wowcher and Emma Sleep, and how to set up an honest timer in WooCommerce before Black Friday.

Nov 8, 2026

Legal guarantee notice in WooCommerce: Ireland rules

From 27 September 2026 an online shop selling goods to consumers in Ireland must show the EU harmonised notice on the legal guarantee, and the GARAN label where the producer offers a durability guarantee. What S.I. No. 124/2026 changes, where each element goes and how to build it in WooCommerce.

Explore other WordPress services and knowledge base