# Access\_key header is not valid

**URL:** <https://community.rapyd.net/t/access-key-header-is-not-valid/1568>\
**Category:** ⚙️ API\
**Tags:** open-discussion, get-started\
**Created:** [April 13, 2022, 9:23pm UTC](https://community.rapyd.net/t/access-key-header-is-not-valid/1568 "2022-04-13T21:23:21Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![RW\_W](https://sea2.discourse-cdn.com/flex016/user_avatar/community.rapyd.net/rw_w/32/1569_2.png) [@RW\_W](https://community.rapyd.net/u/RW_W)\
**Post date:** [April 13, 2022, 9:23pm UTC](https://community.rapyd.net/t/access-key-header-is-not-valid/1568/1 "2022-04-13T21:23:21Z")

</div>

Hey!

I tried to make payments but I get the message: “access\_key header is not valid”. When I try to use the sandbox keys it does work, so the code should be good(?)

I checked the keys multiple times and they’re correct

Does someone have an idea what this could be?

Thanks,  
RW

---

<div class="post-metadata">

**Author:** ![drew.harris](https://sea2.discourse-cdn.com/flex016/user_avatar/community.rapyd.net/drew.harris/32/1259_2.png) [@drew.harris](https://community.rapyd.net/u/drew.harris)\
**Post date:** [April 14, 2022, 2:33pm UTC](https://community.rapyd.net/t/access-key-header-is-not-valid/1568/2 "2022-04-14T14:33:07Z")

</div>

Hey, @RW_W welcome to the community! So I had this error the other day myself and I had switched the keys. Can you make sure the keys which you already verified are correct are in the right order? If you can give us a screenshot without your keys of the code we can have someone take a look as well if the switching of keys doesn’t solve your challenge. @drew.harris

---

<div class="post-metadata">

**Author:** ![drew.harris](https://sea2.discourse-cdn.com/flex016/user_avatar/community.rapyd.net/drew.harris/32/1259_2.png) [@drew.harris](https://community.rapyd.net/u/drew.harris)\
**Post date:** [April 23, 2022, 7:07pm UTC](https://community.rapyd.net/t/access-key-header-is-not-valid/1568/3 "2022-04-23T19:07:38Z")

</div>

Hi @RW_W just checking in to see if you still had any questions.

---

<div class="post-metadata">

**Author:** ![CharlesDorsett](https://sea2.discourse-cdn.com/flex016/user_avatar/community.rapyd.net/charlesdorsett/32/47_2.png) [@CharlesDorsett](https://community.rapyd.net/u/CharlesDorsett)\
**Post date:** [May 31, 2022, 4:08pm UTC](https://community.rapyd.net/t/access-key-header-is-not-valid/1568/4 "2022-05-31T16:08:01Z")

</div>

When you get your access keys from the Client Portal, make sure you are getting the sandbox keys - flip the toggle at the lower left of the page. The production keys won’t work in the sandbox!
