Here is a guide to solve fatal errors related to “Uncaught WC_Data_Exception: Invalid billing email address “ [your directory where you installed WordPress].

Table of content

  1. Introduction Fatal Error
  2. How fatal errors impact your website
  3. What is an Uncaught WC_Data_Exception
  4. Invalid Billing Email Address Error Log
  5. The process to solve Uncaught WC_Data_Exception

Introduction To Fatal Errors

Fatal errors are critical errors – for example, instantiating an object of a non-existent class, or calling a non-existent function. These errors cause the immediate termination of the script, and PHP’s default behavior is to display them to the user when they take place.

This error is usually seen when you take a back-up of your live wordpress webiste using plugin like All-in-One WP Migration or some sort of backup plugin. When you import the backup files these plugins changes the admin email to domain@localhost or foldername@localhost.

How fatal errors impact your website

Fatal errors are to be resolved immediately. As mentioned above these errors tends to cause the immediate termination of the script – What this means is your website will not be rendered.

What is an Uncaught WC_Data_Exception Error

Uncaught WC_Data_Exception error simply means that we have some data that doesn’t match the data format

In this case, it simply means that you have an email address in your database that doesn’t match the format of the email address. This error may occur if you accidentally change the email address to a name or to some other sort of string.

Invalid Billing Email Address Error Log

[03-Sep-2021 13:08:50 UTC] PHP Fatal error: Uncaught WC_Data_Exception: Invalid billing email address in E:\work\htdocs\agency\wp-content\plugins\woocommerce\includes\abstracts\abstract-wc-data.php:856

The process to solve Uncaught WC_Data_Exception: Invalid billing email address

  1. Go to your database i.e phpmyadmin
  2. Go to the wp_options

    Invalid billing email address phpmyadmin panel
    Invalid billing email address phpmyadmin panel
  3. Click on  edit admin_email row
  4. Change the  admin_email to a real email

    Invalid billing email address phpmyadmin panel
    Invalid billing email address phpmyadmin panel
  5. Come back to your Dashboard and refresh the page
  6. Go to Setting > General Setting > Administration Email Address (Now the Administration Email Address is what you put in the database)
  7. Don’t change anything here just scroll down to the bottom and hit the save changes button
  8. Now from your dashboard go to User > Edit Admin if the email box is not updated automatically change the email here also.
  9. Scroll down to the bottom and update the changes
  10. Done
  11. Refresh your website. You don’t see any error

Conclusion: This error occurs when an email address is not the real one. It might be domain@localhost or some sort of name, changing the email field in the wp_options will remove this error. The proper email input field expect the email format to be name@domain.com

 

Note: If you want more help please contact us using  Contact Us Form here.

Leave a Reply

Your email address will not be published.