Removing The Company Name Field From The WooCommerce Checkout

Last Updated on 8th October 2019
Table of Contents

A common request we receive from our clients is to remove the company name field from the WooCommerce checkout.

This makes a lot of sense, especially if you are selling to consumers rather than businesses. If you are a consumer focused ecommerce store, having the company name field is just added friction on your checkout and something that could potentially confuse customers if they’re not sure whether it needs to be filled out or not.

Thankfully, there’s a very simple method for removing the company name field from the WooCommerce checkout that you can implement on your store.

Removing company name from WooCommerce checkout

WooCommerce makes it really easy to customise the Checkout through the use of hooks and filters.

To remove the company name field from the WooCommerce checkout, all that we need to do is hook in using the woocommerce_checkout_fields hook and then apply a filter to unset the [billing] [billing_company] field from the array returned.

Access the WordPress editor

The first step is to access the built in WordPress code editor by going to Appearance > Theme Editor / Editor

Access your functions.php file

The functions.php file is used for customising your WordPress website. Note, you must have a child theme setup to follow these steps.

If you don’t have a child theme setup, set one up then come back to this article.

Before you make any changes to your PHP file, take a backup. Either copy and paste the contents into an empty notepad document, or download a copy from cPanel File Fanager if you know how to do this.

Copy and paste the below snippet into your functions.php file

The below PHP snippet will remove the company name field from your WooCommerce checkout. It uses a filter to target the WooCommerce checkout fields then unsets the company field, removing it from your checkout page.

Click update on your functions.php file. Now if you refresh your checkout page, the company name field should have vanished.