# 403 Forbidden (nginx) error - (reverse proxy)

**URL:** https://community.kinsta.com/t/403-forbidden-nginx-error-reverse-proxy/1096
**Category:** Application Support
**Created:** [November 5, 2021, 2:10pm UTC](https://community.kinsta.com/t/403-forbidden-nginx-error-reverse-proxy/1096 "2021-11-05T14:10:34Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![lucas7c](https://avatars.discourse-cdn.com/v4/letter/l/67e7ee/32.png) [@lucas7c](https://community.kinsta.com/u/lucas7c)
#### Post date: [November 5, 2021, 2:10pm UTC](https://community.kinsta.com/t/403-forbidden-nginx-error-reverse-proxy/1096/1 "2021-11-05T14:10:34Z")

</div>

Hi,  
I had installed devkinsta well. Then I imported the website from kinsta.

But I get a 403 Forbidden error, can not open the website and the wpadmin page.

My website is a reverse proxy website. I want to know if this reverse proxy is related? What do I need to do? Thank you

The location of the real root directory of my local file:

Users\example\DevKinsta\public\examplecn\cn\wp-admin

devkinsta site host:  
://examplecn.local/

thanks

---

<div class="post-metadata">

### Author: ![michael](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/michael/32/31_2.png) [@michael](https://community.kinsta.com/u/michael)
#### Post date: [November 5, 2021, 2:44pm UTC](https://community.kinsta.com/t/403-forbidden-nginx-error-reverse-proxy/1096/2 "2021-11-05T14:44:24Z")

</div>

Hi @lucas7c ! I’m happy to help. Yeah, due to it being a reverse proxy, unfortunately it’ll require a few additional configurations here for it to work. This may not be ideal as any edits made the nginx configuration will reset on any restarts/shutdowns/upgrades thus having to make those configurations again. [There is a feature request here for the ability to edit nginx easily](https://community.kinsta.com/t/ability-to-upload-custom-nginx-rules/378).

If you’re interested in editing nginx, [we have a post here that might help with that](https://community.kinsta.com/t/are-nginx-rules-transferred-to-and-from-devkinsta/366/2). Essentially you’ll need to change the root directory on nginx to load from the reverse proxy sub-directory. Additionally, you’ll need to add `rewrite ^/subsite-will-load-here/(.*)$ /$1 last;` within nginx to ensure it loads from the sub-directory.

Let me know if you have any questions along the way on setting this up.

---

<div class="post-metadata">

### Author: ![lucas7c](https://avatars.discourse-cdn.com/v4/letter/l/67e7ee/32.png) [@lucas7c](https://community.kinsta.com/u/lucas7c)
#### Post date: [November 5, 2021, 5:05pm UTC](https://community.kinsta.com/t/403-forbidden-nginx-error-reverse-proxy/1096/3 "2021-11-05T17:05:05Z")

</div>

Thank you very much for your reply, I will try it tomorrow. Thank you.
