1. Documentation /
  2. How to Reset API Keys in WooCommerce

How to Reset API Keys in WooCommerce

What are APIs?

↑ Back to top

APIs allow two separate services to connect and communicate. For example, WooCommerce can communicate with the Stripe API so that payments on a WooCommerce store can be processed via Stripe. Once that has been done, Stripe can communicate to WooCommerce that the order has been paid for. 

In order to do this safely and uniquely, these API communications are protected with keys: unique identifiers to make sure that the accounts on both sides of the communication are owned by the same people. 

The keys can be added in two ways:

  • External: The API keys are generated by a 3rd party and used on the WooCommerce store to establish the connection. The majority of payment gateways are examples of this. 
  • Internal: The API keys are generated in the WooCommerce store and then saved on the 3rd party service. 

API keys give a lot of power. If you suspect that anyone else has had access to them, update them immediately. Below, we will give a few examples of how to do this.

While you are resetting the API keys, this connection will not be functioning until you’ve reconnected the service. For example, if you reset your payment gateway API keys, you will not be able to receive payments while you are in the process of updating the keys.

How to Reset Payment Gateways API Keys

↑ Back to top

With most of the payment gateways offered via WooCommerce.com, the API keys are generated automatically once you connect your store. In most cases, disconnecting and reconnecting your store to the provider will reset the API keys. 

Here are a few examples of some of our bigger payment gateways. 

How to reset or “Roll” API Keys for Stripe

↑ Back to top
  • In your WooCommerce store, go to: WP Admin > WooCommerce > Settings > Payments > Stripe > Settings
  • Once there, click the Edit Account Keys
  • There you’ll see the current Public and Secret keys currently in place on your account.Note that live keys and test keys are different
  • The next step is revoking the API keys on the Stripe side:
    • Head to the API keys section of your Stripe Account at https://dashboard.stripe.com/apikeys
      • Next to “Secret Key”, select the ellipsis icon (...) > Roll Key…
      • Fill in the details
      • Select “Roll API key”
    • After rolling your API Key, copy your new Secret key to your settings and replace the old one!

How to reset API Keys for PayPal Payments

↑ Back to top
  • In your WooCommerce store, go to: WP Admin > WooCommerce > Settings > Payments > PayPal
  • There, take note of the client ID (to later double check that the keys have been updated)
  • Then, select “Disconnect”
  • Finally, select “Connect to PayPal” and go through the process of connecting your account

Double-check that the new client ID is different from the one you used to have. This is an indication that your API keys have indeed been reset. 

How to Reset WooCommerce REST API Keys

↑ Back to top

Resetting the WooCommerce REST API keys is done in a different section. Note that once you’ve reset the keys you will need to update those keys in the service that you’ve connected them with. 

  • Go to: WP Admin > WooCommerce > Settings > Advanced > Rest API
  • There, select “Revoke key”
  • Now, select “Add Key” and reconnect your 3rd party service with the new keys you’ve generated

Questions and Support

↑ Back to top

Do you still have questions and need assistance? 


The most customizable ecommerce platform for building your online business.

  • 30-day money-back guarantee
  • Support teams across the world
  • Safe and secure online payment