# URL301

{% hint style="info" %}
This is provider specific type of record and not a DNS standard. It may behave differently for each provider that handles it.
{% endhint %}

#### Namecheap

This is a URL Redirect record with a type of "Permanent", it creates a 301 redirect to the target.

You can read more at the [Namecheap documentation](https://www.namecheap.com/support/knowledgebase/article.aspx/385/2237/how-to-set-up-a-url-redirect-for-a-domain/).

#### Porkbun

This creates a permanent (HTTP 301) redirect to the target URL. By default, it includes wildcard subdomains but does not include the URI path in redirection.

Example:

{% code title="dnsconfig.js" %}

```javascript
D("example.com", REG_PORKBUN, DnsProvider(DSP_PORKBUN),
    URL301("redirect", "https://example.org"),
);
```

{% endcode %}


---

# Agent Instructions: 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:

```
GET https://docs.dnscontrol.org/language-reference/domain-modifiers/url301.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
