Sequential Order Numbers Pro

Overview ↑ Back to Top

Sequential Order Numbers Pro is a WooCommerce extension that enhances the functionality of your WooCommerce site by allowing you to have incrementing order numbers rather than random ones. Additionally, you can set a starting number, order number length, custom prefix and/or suffix, and skip free orders, giving you full control over your shop’s order numbers.


  • Provides sequential rather than random order numbers
  • Start the order numbering at any number (or for shops with existing order numbers, any number greater than your current largest order number)
  • Set a custom order number prefix or suffix
  • Enable or hide the default hash (#) before order numbers on the backend/admin
  • Include the current day, month, or year in your custom order number prefix or suffix
  • Include the current time: hour, minute, second in your custom order number prefix or suffix
  • Order number length can be set, automatically adding as many zeroes to the beginning of the order number as needed
  • Orders with only free products can be excluded from the paid order sequence for accounting purposes, and assigned their own custom prefix

Installation ↑ Back to Top

  1. Download the extension from your dashboard
  2. Go to Plugins > Add New > Upload and select the ZIP file you just downloaded
  3. Click Install Now, and then Activate
  4. Go to WooCommerce > Settings > General, scroll down to “Order Numbers” and read the next section to learn how to setup and configure the plugin.

Setup and Configuration ↑ Back to Top

No configuration is required for this plugin; in an empty site, orders will automatically be numbered beginning at 1, and with existing orders the numbering will pick up from the largest order number.

Optional configuration settings to customize the order number can be found by going to WooCommerce > Settings > General:

WooCommerce Sequential Order Numbers Pro Admin Settings

Highly Configurable Custom Order Numbers

Order Number Start
This is the starting number for any newly placed orders. This can be used to start order numbering at an arbitrary point (ie 1000) as long as it is higher than the current largest order number, or can be used to advance the order number in a shop with existing orders. For instance, if the current highest order number is 24 and this is set to 500, the next orders placed will be: 500, 501, 502, etc.
You can also control the order number minimum length by including leading zeroes to pad your order numbers with at least that many zeroes and achieve a fixed length. For instance, setting the order number start to "00001" will result in the following order number sequence: 00001, 00002, 00003, etc.
Changing this setting does not affect existing orders!
Hash Before Order Number
Enabled by default, this will display a hash (#) before order numbers on the frontend and admin. Note that this is purely for cosmetic purposes, and this hash is not stored in the database as part of the order number. Usually, this is helpful for users who do not add a custom prefix.
Order Number Prefix
Allows you to set a custom order number prefix; this can contain any combination of characters, or patterns as described below. Setting this does not affect existing orders.
Order Number Suffix
Allows you to set a custom order number suffix; this can contain any combination of characters, or patterns as described below. Setting this does not affect existing orders.
Skip Free Orders
With this enabled, orders with only free products and no additional fees or costs will be excluded from the paid order sequence. Useful when required by certain accounting rules.
Free Order Identifier
This option is only available when the Skip Free Orders option is enabled. This allows you to set a prefix for the free orders numbering sequence so you can have for instance: FREE-1, FREE-2, FREE-3, etc.

For example, if the starting order number is set to 1000, Order Number Length is set to "5" by making the order number start "01000", Order Number Prefix is set to "AA-" and Order Number Suffix is set to "-ZZ", order numbering will be as follows: AA-01000-ZZ, AA-01001-ZZ, AA-01002-ZZ, etc.

Usage ↑ Back to Top

There are two different scenarios to consider: activation in a site with existing orders, activation in site with no orders.

When activated in a site with pre-existing orders, the existing order numbers will be unaffected, and order numbering for newly placed orders will directly follow the largest existing order number, or the configurable start number, whichever is bigger.

When activated in a site with no orders, the first order number will be 1; this value can be configured as explained in the Configuration section above.

Prefix/Suffix Patterns ↑ Back to Top

The following patterns can be used within the order number prefix/suffix fields to add special values to the custom order number. For instance, they allow you to have the current day, month, or year within your order numbers. Any number of patterns can be used, and in any order, and new patterns will continue to be added as they are requested.

Day of the month without leading zeros
Day of the month, 2 digits with leading zeros
Numeric representation of a month, without leading zeros
Numeric representation of a month, with leading zeros
A two digit representation of a year
A full numeric representation of a year, 4 digits
24-hour format of an hour without leading zeros
24-hour format of an hour with leading zeros
Minutes with leading zeros
Seconds, with leading zeros

Example pattern usage of a custom order number prefix including the current date: WT-{YYYY}{MM}{DD}

Compatible Plugins ↑ Back to Top

This list is by no means exhaustive, but lists some of the plugins that are known to be compatible with the Sequential Order Numbers plugin:

Note that even if you don’t see your favorite plugin or gateway listed here, it doesn’t necessarily mean that the plugin isn’t compatible. Compatibility can be added to nearly any plugin or gateway – we advise getting in touch with the author of the plugin if it’s not compatible, and be sure to ask nicely!

Incompatible Gateways ↑ Back to Top

This list is by no means exhaustive, but lists some of the gateways that are known, due to gateway limitations, to be incompatible with the Sequential Order Numbers plugin:

  • Amazon FPS
  • PayPal Payments Advanced
  • PayU
  • PayU Turkey
  • RedSys

Frequently Asked Questions ↑ Back to Top

Q: I tried setting the starting order number but it’s not being used. What’s the problem?
A: If you’re operating in an environment with existing orders you must use a starting number which is greater than the biggest existing order number. This is done so that historical order numbers are not altered.

Q: This is supposed to be compatible with the Order CSV Import Suite, but my Sequential Order Numbers are not showing. How do I fix this?
A: You’ll need to set both the order_number and order_number_formatted as described in our CSV Import Docs, as the “order_number” corresponds to the order id.

Q: This plugin works great, but the order numbers aren’t being used by plugin ___________, what gives?
A: Third-party plugins can generally easily be made compatible with the Sequential Order Number Pro plugin. Get in touch with the particular plugin author and see if they would be willing to upgrade their plugin.

Also verify that your gateway isn’t one of the few on the short list of gateways which due to technical limitations can not be made compatible.

Q: I’m a plugin author and I want to make my plugin compatible with WooCommerce custom order numbers so it will support the Sequential Order Numbers plugin, as well as any other plugin that modifies order numbers. How do I go about this?
A: For most plugins this is an easy process, simply replace the post-id order number (ie $order->id) with $order->get_order_number() anywhere that the order number is displayed. When sending the order number to outside systems, such as payment gateways you may want to use something like the following: ltrim( $order->get_order_number(), __( '#', 'hash before order number', your-plugin-text-domain ) ) where the ltrim is used to cut off the leading hash that would otherwise be included. Orders are still looked up and handled internally by the underlying post id, so these changes are made only for display purposes.

Generally the only time that adding support gets tricky is with redirect-based payment gateways, since you need to pass both the underlying post_id, for looking up the order on the post-back, as well as the get_order_number() value for displaying within the gateway order manager. Some gateways like CyberSource make it easy to pass custom fields, others like Braintree require the customer to register the custom field, and with still others it’s not even possible.

Q: Why does the URL refer to the Order ID and not the Sequential Order Number?
A: The order ID in the URL is used to retrieve the correct order from the database and, while it is possible that other information could be used, it would require modification of WooCommerce core. It is not possible to use the number generated by Sequential Order Numbers Pro as there are too many possible order number variations that are not compatible with URL parameters – the hash for example.

Questions & Feedback ↑ Back to Top

Have a question before you buy? Please fill out this pre-sales form.

Have some feedback for us on this documentation? Please let us know so we can make improvements!
Take me to the feedback form.

Back to the top