Skip to main content

When hooking up payment and shipping in Magento there are a few common errors that you may see. The most common one is one from Paypal that says "PayPal gateway has rejected the request. Security header is not valid (#10002: Security error)".

Why Security Header Is Not Valid:

The 'Security header is not a valid' error is only caused for two reasons:

Stay in the loop! Discover what’s new in the world of ecommerce.

Stay in the loop! Discover what’s new in the world of ecommerce.

  • Hidden
  • Hidden
  • No spam, just quality content. Your inbox is safe with us. For more details, review our Privacy Policy. We're protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.
  • This field is for validation purposes and should be left unchanged.

Wrong Credentials

Make sure that you've inputted your API Username, API Password, and API Signature correctly. Sometimes it happens that, during a copy/paste, a space is accidentally added and this triggers the error. Double-check this setting in the admin panel of your Magento store. Worst comes to worst, type out all the information by hand instead of copy/pasting it.

The Wrong Endpoint

This error would come up if you send the data to the wrong endpoint. Make sure that you send the live credentials and data to our live endpoint. When you want to test your store make sure that you use our test endpoint and the credentials from your sandbox test account. If you are using a third-party shopping cart, make sure that your store is running a test or live mode, regarding which credentials you are using.

Check Your Credentials Here:

FOR LIVE

https://api-3t.paypal.com/nvp?&user=xxxxxxxxxx&pwd=xxxxxxxxxx&signature=xxxxxxxxxx&version=70.0&METHOD=SetExpressCheckout&RETURNURL=http://www.paypal.com/test.php&CANCELURL=http://www.paypal.com/test.php&PAYMENTACTION=Sale&AMT=50&CURRENCYCODE=USD

FOR SANDBOX

https://api-3t.sandbox.paypal.com/nvp?&user=xxxxxxxxxx&pwd=xxxxxxxxxx&signature=xxxxxxxxxx&version=70.0&METHOD=SetExpressCheckout&RETURNURL=http://www.paypal.com/test.php&CANCELURL=http://www.paypal.com/test.php&PAYMENTACTION=Sale&AMT=50&CURRENCYCODE=USD

Just Substitute the user, PWD, and signature and enter in your browser. You should get ACK = SUCCESS if you have input your credentials correctly.

It should give you a response like this:

TOKEN=EC%2d6692632958132974V&TIMESTAMP=2017%2d05%2d15T21%3a16%3a02Z&CORRELATIONID=eec52ef2bb94d&ACK=Success&VERSION=70%2e0&BUILD=33490117

You can also get your credentials here: https://www.paypal.com/cgi-bin/webscr?cmd=_get-api-signature&generic-flow=true

Good luck!

Need More Help?

Subscribe to the Ecomm Manager Newsletter to keep in the loop with fresh articles, podcasts, how-to guides, tool reviews, updates, deals, and product exclusives.

By Michael Cristancho

I'm a Digital Commerce and Experience evangelist who enjoys engaging in thought-provoking conversation and mutual exploration. I am a strong believer that learning never ends, and each day brings another opportunity to grow as an individual and professional.