Swift Commerce
Menu
Features

Your next store tool is here.

Explore 16 store features. Unlock their full capabilities with Pro.

Sell & personalize

Product Bundles

Sell complementary products together.

Product Addons

Offer extra choices and personalisation.

Subscriptions

Offer products on a recurring schedule.

Product Quantity Limits

Set minimum and maximum quantities.

Shopping experience

Ajax Search

Show products as shoppers type.

Wishlist

Give saved products a place to wait.

Currency Switcher

Display prices in a familiar currency.

Add to Cart Popup

Confirm additions and the next step.

Customer relationships

Cart Recovery

Follow up on unfinished purchases.

Back In Stock

Notify interested shoppers when stock returns.

Shipment Tracking

Share tracking details for orders.

Email Customizer

Customize supported customer emails.

Security & checkout

Registration & Access

Build forms, verify emails and review accounts.

reCAPTCHA

Add checks to supported forms.

Cookie Consent

Offer preferences and managed integration gating.

Checkout Field Editor

Adapt supported checkout fields.

View all features · See Pro plans

Solutions

Built around the way you work.

Store owners

Tools for the everyday work of running a store.

Freelancers

Build and hand over a more consistent setup.

Agencies

Bring a familiar toolkit to client projects.

Integrations

Explore supported connections and compatibility.

Resources

A little help goes a long way.

Documentation

Setup guides and feature reference.

Blog & updates

Product news and store ideas.

Contact us

Talk to the Swift Commerce team.

About Swift Commerce

The people and thinking behind the suite.

Affiliate program

Earn commission by referring new customers.

Request a feature

Tell us what your store needs next.

Report a bug

Help us investigate a problem.

← Back to articles

How to Add Custom Order Fields to WooCommerce Checkout Blocks

Add custom order fields to WooCommerce Checkout Blocks with Swift Commerce. Follow the text-field setup, optional Pro examples and a complete test-order checklist.

Vector illustration of an order-reference field being added to a block-based checkout form.

Need a purchase-order reference, a short gift note or another detail attached to a customer’s order? You can add custom order fields to WooCommerce Checkout Blocks with Swift Commerce’s Checkout Field Editor, without putting a code snippet into your theme.

The important part is “Checkout Blocks.” A field added through an old classic-checkout hook will not automatically appear in the block checkout. Swift Commerce uses WooCommerce’s additional-checkout-fields system for the supported fields in this guide.

We will add an optional order-reference field with the Free plugin, check where it appears and place a test order to verify the saved answer. There are also optional Pro examples for a dropdown and checkbox.

Check the supported fields before you begin

For this walkthrough, have WooCommerce and Swift Commerce active, a working block-based checkout and a staging site where you can place a test order. Keep WooCommerce current so its additional checkout fields API is available.

  • Free: text-based custom order fields. Swift Commerce maps Text, Number, Email, Phone and URL field types to the Blocks text field, with applicable server-side validation.
  • Pro: supported Select and Checkbox fields, in addition to the text-based options.
  • Not part of this Blocks integration: file uploads, textarea, hidden fields, date/time fields, content-only elements and fields with conditional logic enabled.

That last point is specific to Swift Commerce’s current Blocks integration. WooCommerce’s own API and classic checkout have different capabilities. Do not assume that every field type visible in a general field picker can be used in the block checkout.

1. Confirm that your checkout uses the Checkout block

  1. Open WooCommerce → Settings → Advanced and identify the page assigned as your checkout.
  2. Go to Pages and edit that assigned page.
  3. Open the editor’s List View and look for the WooCommerce Checkout block.
  4. If the page instead contains a Shortcode block with [woocommerce_checkout], it is using classic checkout, not Checkout Blocks.

Do not replace a working checkout on your live store just to follow this tutorial. If you are moving from classic checkout, test your payment methods, shipping methods and other checkout extensions on staging first.

This guide continues with the block-based checkout. The same settings screen also contains classic-checkout controls, which is why checking the page first saves a lot of confusion.

2. Enable Checkout Fields in Swift Commerce

  1. Open Swift Commerce → Checkout Fields. Use the feature search if you do not immediately see it in the sidebar.
  2. Make sure the feature’s main toggle is enabled.
  3. Open the Field Editor tab.
  4. Locate the Additional information section and make sure the section itself is enabled.
Swift Commerce Checkout Field Editor showing Quick Add Fields and the Billing details and Shipping field sections.

For Blocks, add your new field under Additional information or Order notes in Swift Commerce. Both supported section types are registered in WooCommerce’s Order information location. A custom field placed under Billing details or Shipping is not added to the block checkout by this integration.

3. Add an order-reference text field

  1. In Additional information, click Add Field.
  2. Choose Text.
  3. In the field dialog’s General tab, set Label to Order reference.
  4. Set Field Key to order_reference.
  5. Keep Field Enabled switched on.
  6. In Validation, leave Required Field off for this example. Set Max Length to 40.
  7. Click Add Field to finish the new field, then click the page-level Save Changes.
Add Field button highlighted in the Billing details section of the Swift Commerce Checkout Field Editor.
The Add Field control is shown under Billing details. For Checkout Blocks, use Add Field in Additional information or Order notes instead.
Add Field to Billing details dialog with the Text field type highlighted and advanced field options below.
Field-type picker. For this Blocks tutorial, open it from Additional information or Order notes, not Billing details.
Order Reference field settings with the order_reference key, placeholder, enabled toggle and Add Field button.

An order reference is useful for customers who want their own internal reference recorded against a purchase. It does not generate a purchase order, approve a credit account or change your payment terms.

Use a stable key that is unique among your fields. Swift Commerce adds its namespace when registering the field with WooCommerce, so enter order_reference in the field editor rather than typing a separate API namespace into the key.

If your field really is essential to fulfilling the order, enable Required Field instead. Avoid making optional business information mandatory for every customer.

4. Add a dropdown or checkbox if you use Pro

You can stop after the text field. If you need controlled answers, Swift Commerce Pro also supports Select and Checkbox fields in this Blocks workflow.

Example: ask how the customer found your store

  1. Click Add Field in Additional information and choose Select.
  2. Use How did you hear about us? as the label and order_source as the field key.
  3. In Options, add values and labels such as search / Search engine, social / Social media and friend / A friend.
  4. Keep it optional, leave conditional logic disabled and save both the field and the feature page.
Options for a How did you hear about us dropdown, with Search, Social Media and A Friend choices.

Keep stored option values stable after orders start using them. The readable labels can explain the choices; the values identify the submitted answers.

Example: record a simple packing preference

Add a Checkbox field under the same section, label it Please leave out the printed packing slip and use omit_packing_slip as its key. Keep it optional and save.

This records a preference on the order. It does not automatically change the behavior of a separate packing-slip or fulfillment plugin. Confirm how your team will use the answer before offering the option to customers.

5. Check the Order information block

Return to your checkout page in the WordPress editor. Inside the Checkout block’s structure, find Order information. That is where these fields are rendered, rather than in the billing-address inputs.

Classic WooCommerce checkout showing Order Reference and How did you hear about us fields in Billing Details.
Classic-checkout example only. In Checkout Blocks, the supported fields in this guide appear under Order information, not Billing Details.

WooCommerce lets you move the Order information block within the supported checkout structure. Its additional checkout fields documentation explains this location and how order-only data is stored.

If a previously customized checkout template is missing Order information, restore that inner block in the Checkout structure before expecting the fields to appear. Save any editor changes, then inspect the actual customer checkout.

The Blocks interface controls the rendered layout. Do not expect Swift Commerce’s classic-checkout width, placeholder or description settings to produce an identical design in Checkout Blocks.

6. Place a test order and check the saved values

  1. Open the storefront in a private browser window and add a product to the cart.
  2. Proceed to the assigned checkout page.
  3. Find Order reference in Order information and enter a recognizable test value, such as TEST-REF-104.
  4. Try a value longer than the configured maximum and confirm that validation prevents an invalid submission.
  5. Enter a valid value and complete an order using a test payment method on staging.
  6. Open the order under WooCommerce → Orders and confirm that the additional order-field value was saved.
  7. Check the customer’s order details and relevant order email as well, so you know how your current WooCommerce setup presents the data.

Also place a test order with the optional field left empty. If you made a field required, test an empty submission and confirm that it cannot complete.

These are order-specific answers. They are not a new saved billing-address field, and you should not expect a previous order reference to become a permanent customer-profile value.

If your field does not appear

  • Confirm that you are testing the assigned Checkout page, not another page with a similar name.
  • Check that the Checkout Fields feature, the field and its section are all enabled and saved.
  • Use Additional information or Order notes for the custom field, not Billing details or Shipping.
  • Use a supported type. Textarea is not the same as Text in this integration.
  • Leave the field’s conditional logic disabled. Fields with conditional logic enabled are excluded from this Blocks registration.
  • For Select or Checkbox, confirm that Swift Commerce Pro is active and that the dropdown has valid options.
  • Check for the Order information inner block and clear any page cache after saving changes.

Do not keep adding duplicate copies of the field to make it appear. Work through the location and support checks first. If it remains missing, share the field type, section, WooCommerce version and checkout type with support.

Questions about custom order fields in Checkout Blocks

Can I use this to remove or reorder core billing fields?

Not through this additional-order-field workflow. Editing core address fields and adding order-specific fields are separate tasks. Classic-checkout field settings should not be treated as a complete Checkout Blocks editor.

Can I use a date picker or conditional show/hide rule here?

Not with Swift Commerce’s current Blocks integration described above. Advanced options available for classic checkout are not automatically supported in Blocks, even when Pro is installed. Verify the specific feature before building a checkout around it.

Do I have to edit functions.php?

No. Swift Commerce handles field registration for the supported configuration. Avoid adding a second code snippet for the same field, which can introduce duplicate IDs or overlapping behavior.

For the rest of the settings, keep the Checkout Field Editor documentation nearby. Start with one useful field, verify the saved order, and only then add the next one.

For the next setup task, see conditional fields on classic checkout, file uploads on classic checkout.