> For the complete documentation index, see [llms.txt](https://guides.engels.zip/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://guides.engels.zip/pterodactyl-setup/02-creating-urls/02c-setting-up-cors/02ca-cors-option-1-secure.md).

# 02ca) CORS Option 1 (secure)

### Setting up CORS (secure)

1. We must enable CORS so that the `pt-panel` can connect to the reverse-proxied `pt-wings` URL and vice versa.
2. To accomplish this, we must navigate to the `pt-wings` URL settings. In my case, I choose the `pt-wings.engels.zip` settings-wheel. <img src="https://i.imgur.com/SWILIh4.png" alt="" data-size="line">
3. In there, go to the "**Security**" tab.
4. Scroll down to the "**Custom CORS Origin"**
5. Write the url of your `pt-panel` in the **Custom CORS Origin** field, and press `Save`.
6. In my case, that would be: `https://pt-panel.engels.zip`. Remember to include the `https://`.

<figure><img src="https://i.imgur.com/03QlI0I.gif" alt=""><figcaption><p>Safe and secure :)</p></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://guides.engels.zip/pterodactyl-setup/02-creating-urls/02c-setting-up-cors/02ca-cors-option-1-secure.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
