67 Responses

  1. BobWP
    BobWP June 28, 2013 at 17:15 | | Reply

    Perfect timing. I was just going to do this and had found a tutorial on YouTube but it recommended putting this same code in a woocommerce file which kind of freaked me out. Good to see it works in the theme.php file as well … cheers!

  2. Karen
    Karen September 12, 2013 at 04:44 | | Reply

    Thank you for this code! Do you know how i can do this same thing for the Edit Address & My Account pages in Woocommerce? Thanks!

    1. Wesley Asher
      Wesley Asher April 5, 2014 at 19:59 | | Reply

      I know this is like wicked late but try this:

      function wpdebug_disable_account_addresses( $fields ) {
      return array();
      add_filter( ‘woocommerce_my_account_get_addresses’, ‘wpdebug_disable_account_addresses’ );

  3. Karen
    Karen September 12, 2013 at 16:22 | | Reply

    That plugin was mentioned in the article already, and I do use that plugin for the checkout page. But I need the same limited fields ( First name, Last name, and email address only) on the Edit Address page and My Account page that are part of Woocommerce. Can anyone help me figure out how to do that?

  4. vj
    vj November 2, 2013 at 22:09 | | Reply

    This worked a treat – thanks!

  5. papa0urs
    papa0urs November 22, 2013 at 01:43 | | Reply

    I did it and now i have a blank screen and i cant login my wp account ;(

    1. Peter
      Peter May 5, 2016 at 23:26 | | Reply

      I had this issue as well…

      I wrote how to avoid this here:

    2. adeel khan
      adeel khan September 16, 2016 at 13:01 | | Reply

      just removed extra spaces from function.php file

  6. Andrew Rezk
    Andrew Rezk December 26, 2013 at 02:25 | | Reply

    Thanks much for this helpful info., I used woocommerce checkout manager plugin, it removed all the fields but anyone knows how to remove the billing address title that shows on the checkout page?


    1. Alex
      Alex September 14, 2015 at 12:59 | | Reply

      Hi, you’d need to edit form-billing.php which can be found inside \wp-content\plugins\woocommerce\templates\checkout\ line 23 put two forward slashes \\ infront of _e( this will comment the line out.

      1. Sylvester Sly Lapisang
        Sylvester Sly Lapisang May 7, 2016 at 05:30 | | Reply


  7. Vinny Moreira
    Vinny Moreira January 9, 2014 at 19:06 | | Reply

    It works! Thank you for this code.

  8. Dinga Bogdan
    Dinga Bogdan January 16, 2014 at 11:44 | | Reply

    “If I were you, I would just do it programmatically.” you just made me to get my hands dirty… again 🙂
    Thank you !

  9. sergioronei
    sergioronei August 10, 2014 at 18:01 | | Reply

    Yeah man! Thanks.

  10. Brad
    Brad October 31, 2014 at 16:46 | | Reply

    Worked perfect! Thanks. Is it just me or are there several quarks with WooCommerce? Seems like they would make a lot more money if they offered a pro version for $50 with additional features like this than trying to upsell a boat load of plugins for $100 each that only do one thing.

  11. saimon
    saimon October 31, 2014 at 18:31 | | Reply

    thanks for sharing this tips. it solves my prob..

  12. haru
    haru November 19, 2014 at 08:02 | | Reply

    hi i just want to empty the default billing details from my checkout page is ther any possibility for this.

  13. buscando1milhaoernando
    buscando1milhaoernando December 16, 2014 at 01:30 | | Reply

    Hey Jean, thanks, very nice post!

    Do you know a way (manually or automatic) to remove the whole section “additional information/billing and shipping address”?


    1. Coen
      Coen February 1, 2015 at 14:30 | | Reply

      I’d like to know how to do this too!
      It’s kinda strange when the titles still appear whilst there are no fields below them to fill….


  14. Judah Lamm
    Judah Lamm January 27, 2015 at 17:06 | | Reply

    Hey Jean,

    Thank you for the code! I was wondering if you knew how to turn it into more of an if statement? Meaning, I have two options on my checkout page (CC & Paypal) if the user clicks on Paypal, I would like your code to run.

    Do you know how/where to do that?


  15. Lana
    Lana March 2, 2015 at 02:27 | | Reply

    This totally fucked up my site. Now I can’t access it!!

    1. Judah
      Judah March 2, 2015 at 03:13 | | Reply

      Hey Lana.

      Where did you place the code?

      If you access your site via ftp, you should be able to locate the file and delete the code you put in.

    2. alice
      alice May 3, 2016 at 05:05 | | Reply

      how to access site via ftp

  16. Anup Dhirwan
    Anup Dhirwan March 7, 2015 at 14:18 | | Reply

    Lana, you might have placed that code inside the braces of already existing code in theme’s functions.php. I did that too and “fucked up my site” anyway, i undo the modification via ftp and added the whole code outside the braces of the already existing code. That did the job.

    1. alice
      alice May 3, 2016 at 04:54 | | Reply

      hello? hope you are online, can you tell me how to undo the modification via ftp? thanks a lot

  17. Harun R Rayhan
    Harun R Rayhan April 6, 2015 at 20:27 | | Reply

    Hay, I want to make it conditional. I’m making it easier, recently I installed BitPay payment method my woocommerce site. I have another payment option. I want to disable Billing details for BitPay only. Not for other payment option. Is it possible??

  18. Smartcooky
    Smartcooky April 30, 2015 at 23:18 | | Reply

    Can you make it work if you want to only have it apply to digital downloads? I will be selling physical products as well, not connected to my digital downloads.TIA.

  19. stanyy
    stanyy June 9, 2015 at 00:32 | | Reply

    The opening php tag looks lost in there. There is no supportive tag at the other end. I guess that may be why it produced a blank page (syntax error) for Lana and papa0urs.

    Thank you for the code. It was useful to me.

    By the way, if anyone would like to remove the header texts, paste the following code in your theme’s custom.css (if you have a child theme, use its style.css instead):

    .woocommerce-billing-fields h3 {
    display: none;
    .add_info_wccs {
    display: none;


    1. stanyy
      stanyy June 9, 2015 at 00:47 | | Reply

      Whoops.. error in code. Please use the this code instead:

      .woocommerce-billing-fields h3 {
      display: none;
      .woocommerce-shipping-fields h3 {
      display: none;

  20. stellen
    stellen August 31, 2015 at 07:59 | | Reply

    Late question, but after removing the billing fields only(keeping shipping fields as such), the order and the email does not have the shipping address. I have set the Delivery Destination to shipping by default.

    Any idea what I did wrong?

    1. zaida
      zaida June 3, 2016 at 01:12 | | Reply

      I have the same situation. Do you know how can I maintain shipping fields and delete billing ones?

  21. Alex
    Alex September 14, 2015 at 13:01 | | Reply

    @JeanGalea: thank you for providing the work around, it was just what I needed 🙂

  22. eyd
    eyd November 15, 2015 at 13:55 | | Reply

    hey there, i am using exactly this method and there’s one strange issue i am experiencing. If a required field is missing, and the payment button is clicked – i get an error: `SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data`
    no matter which field i removed.

  23. sathish
    sathish November 25, 2015 at 02:08 | | Reply

    how to remove default country selected in checkout page?

  24. Florian Stotz
    Florian Stotz December 17, 2015 at 17:28 | | Reply

    Great help – thank you!

  25. ronycandeli
    ronycandeli February 22, 2016 at 19:48 | | Reply

    This plugin can broke AJAX

  26. jobinjose01
    jobinjose01 March 2, 2016 at 21:54 | | Reply

    Great Help thanks 🙂

  27. Borja
    Borja March 3, 2016 at 09:12 | | Reply

    Thanks so much. Works!

  28. hyeondesign
    hyeondesign March 21, 2016 at 14:53 | | Reply

    thank you so much this information!! it works perfectly!

  29. alice
    alice May 3, 2016 at 04:41 | | Reply

    i add the code, then my site turn blank, cant be visited~!!!!

  30. WooSociety
    WooSociety June 14, 2016 at 01:17 | | Reply

    Thanks Jean, we just added this to our site. Worked perfectly!

  31. max
    max July 9, 2016 at 23:26 | | Reply

    How hide or show billing fields after selected a different country or my custom selected?

  32. Jawad Ahmad
    Jawad Ahmad July 19, 2016 at 12:30 | | Reply

    How can we fetch the total bill of the customer order ?

  33. Amit
    Amit August 23, 2016 at 04:22 | | Reply


  34. miguras
    miguras September 3, 2016 at 20:58 | | Reply

    Hello Jean. I made a plugin and it do the same and more. It can remove fields from checkout page, and also can remove/rearrange hooks in single product page and shop page. It is totally free, in fact I uploaded it to WordPress repository. If anyone is interested, here you can download it WooEnhacer – WooCommerce Customizer

  35. Paul
    Paul September 6, 2016 at 14:25 | | Reply

    Hi Jean,

    I have a related issue.

    I want to be able to use a single login for a group of people (players on a team, or teachers in a school) so I can show them team-specific products in a woocommerce store (I already have this set up). BUT, I want each person to use their own info for purchases (name, address, payment details, etc). In other words, I want to capture ORDER info but not USER info, and I don’t want to auto fill any fields upon checkout except the login name to identify the group.

    Is this even possible??

  36. Andrew
    Andrew October 26, 2016 at 12:01 | | Reply

    Hello. I buy theme from themeforest.com, so if something changes new updates will delete this from function.php. So instead I use Child Theme and create function.php, copy this chunk of code, but it doesn’t works… If i put this in parent theme everything good. So how I can make it work?

    PATRICK MCCOY February 4, 2017 at 01:10 | | Reply

    I put in your code as instructed and

    Parse error: syntax error, unexpected ‘<' in /home/content/91/4857491/html/marketplace/wp-content/themes/seller/functions.php on line 304

    it was caused by the superfluous
    <?php in your code, so after having to fix the code through FTP it did nothing. I still have the option to enter billing information on the checkout page :/

  38. Adam
    Adam February 11, 2017 at 22:16 | | Reply

    To anyone having syntax error issues with this –

    1. Use “My Custom Functions” plugin to save yourself the hassle of trying to add code.

    2. Change the name of the fucntion
    add_filter( ‘woocommerce_checkout_fields’ , ‘custom_checkout_fields’ );

    function custom_checkout_fields( $fields ) {

    Note: I changed ‘custom_override_checkout_fields’ to ‘custom_checkout_fields’ as I found there was a duplicate function causing problems.

    If you get really stuck read the readme.txt in the plugin files and there are troubleshooting steps.

  39. Artdrop
    Artdrop March 6, 2017 at 00:26 | | Reply

    Heyall, just wanted to share a tiny little tip for super beginners like me.

    If you already have some custom code in your “functions.php” you must delete the top “<?php" and the last "}" otherwise you may get a pesky error.

    Basically you have to insert just the code, and comment out with "//" the lines that you DO WANT to appear.

    I can confirm that it works like a charm in 2017 as well.

    Last but not least,
    Big thanks to mr. Galea for sharing the code with the world : )

  40. MakeOnlineShop
    MakeOnlineShop April 2, 2017 at 10:41 | | Reply


    Is there any reason why we should not remove the billing address ?

    Thank you for this post.

  41. Seth
    Seth May 5, 2017 at 18:07 | | Reply

    I just entered this into my child themes funcionts.php file and now my site and admin panel are unreachable. Fantastic.

    1. Seth
      Seth May 5, 2017 at 20:55 | | Reply

      I got it to work. Thanks to the tip from the previous ommenter.

  42. Dragan
    Dragan July 7, 2017 at 18:41 | | Reply

    This is great but I have a problem, I can’t remove address and postcode fields, I can remove other fields but these 2 can’t.
    Does anyone know why?

  43. lizy bloom
    lizy bloom September 20, 2017 at 06:59 | | Reply

    Whenever I add code to functions.php it brakes my site (all updated Bridge theme). I know I am just putting it in the wrong place. Can you be a bit more specific about what exactly to put in and where it goes? thanks!

  44. kasper
    kasper September 21, 2017 at 03:06 | | Reply

    Is this working with the woocommerce 3.1.2? I put it in the functions and nothing changed fields are still there ( i am using dokan also but i dont think it has influence) should i remove fields also from template?

  45. ROMAIN
    ROMAIN November 12, 2017 at 07:03 | | Reply

    That doesn’t work for me neither, woocommerce 3.2.1

  46. Eva
    Eva January 31, 2018 at 11:51 | | Reply

    This code does not work for my site? what is wrong?

  47. suresh
    suresh February 26, 2018 at 22:53 | | Reply

    it worked.. thanks for the code..

  48. Nigel
    Nigel August 8, 2018 at 06:25 | | Reply

    This is a really useful piece of code, but I have found a problem when I have ‘guest’ checkout. Essentially, it works fine to hide the country field for example when the purchaser is a registered user and logged in on the web site; but when a purchase is made by someone who is not logged in I still get the missing address error after clicking the purchase button.

  49. Ronda M
    Ronda M August 17, 2018 at 11:53 | | Reply

    On my wordpress site I am currently using woocommerce plugin for checkout with woocommerce First data Payeezy gateway plugin integration for credit cards. The registration form and checkout are all in one page using Registration magic for the registration page that also integrates with woocommerce.
    I hired a developer to design the registration age and woocommerce checkout to one page so there is only registration with payment. While the developer was doing coding he must have added coded that removed the woocommerce fields for billing address, city, state and phone number since it was added to the registration page, but the credit card company tells me that the credit cards are not being processed due to having no billing address and phone number for the credit card holder.
    The developer that did the work states he doesn’t remember where he put the code in the back end to remove the billing address and phone number and is not willing to help find it or add it back in. I have only minimal experience with coding from trial and error on a staging site and youtube but I have tried to uninstall and reinstall woocommerce, tried making a new checkout page and tried a new registration form but the code for the removal must be deep in my theme. I even tried changing from child theme to another theme and making a new checkout form but still the billing details would not show up also tried woo checkout field editor and no matter what I enter it doesn’t add back the woocommerce billing address and phone number to checkout page to checkout page. Current checkout page only shows under billing details: student first name, last name, email and password then goes into registration form that has address and phone number but checkout process isn’t pulling that information into credit card processing. Im stuck at this point. Does anyone know what code I could add to my child theme function.php to add woocommerce billing address and phone number back to the checkout page?
    All plugins are up to date Woocommerce 3.4.4 and Woocommerce First data payeezy Gateway 4.3.3

  50. Rowan
    Rowan September 6, 2018 at 03:58 | | Reply

    Hello do you know how to remove city field from billing order in dashboard ?

  51. vv
    vv September 24, 2018 at 06:29 | | Reply

    I have a custom placeholder text for the phone field. So the code does not hide the phone field. When I remove the custom placeholder text then it will hide. How can I have the placeholder text and hide the billing phone when only virtual products?

  52. Renzo
    Renzo March 5, 2019 at 12:16 | | Reply

    This didn’t let me remove shipping fields . It kept asking for those fields as if they were required

Leave a Reply