Skip to main content

Manage content display

A CDN resource returns a response from the content origin by default. You can temporarily hide content display to make the CDN resource content unavailable to users.

If you have hidden the content display, you can restore it at any time.

Hide content display

You can hide CDN resource content display in one of the following ways:

Set a status code

  1. In the control panel, in the top menu, click Products and select CDN.

  2. In the CDN Resources section, open the CDN resource page → General tab.

  3. In the Return http status code block, select the Enabled checkbox.

  4. In the Response status code field, enter a response code between 100 and 599, except for redirect codes: 301, 302, 303, 307, 308. The entered status code will appear in the CDN resource response.

  5. Optional: in the Response body field, enter the text that will appear in the response.

  6. Click Apply. While settings are being applied, the CDN resource enters the PROCESSING status. You cannot apply other settings during this time. Settings take effect when the CDN resource transitions to ACTIVE.

  7. Purge the CDN resource cache.

Configure a redirect

  1. In the control panel, in the top menu, click Products and select CDN.

  2. In the CDN Resources section, open the CDN resource page → General tab.

  3. In the Return http status code block, select the Enabled checkbox.

  4. In the Response status code field, enter one of the redirect codes: 301, 302, 303, 307, 308.

  5. In the Redirect URL field, enter the link to which the user will be redirected.

  6. Click Apply. While settings are being applied, the CDN resource enters the PROCESSING status. You cannot apply other settings during this time. Settings take effect when the CDN resource transitions to ACTIVE.

  7. Optional: to make the CDN server cache content from the redirect link, enable redirect following. By default, the CDN server only caches the response with the redirect code.

  8. Purge the CDN resource cache.

Restore CDN resource content display

  1. In the control panel, in the top menu, click Products and select CDN.

  2. In the CDN Resources section, open the CDN resource page → General tab.

  3. In the Return http status code block, clear the Enabled checkbox.

  4. Click Apply. While settings are being applied, the CDN resource enters the PROCESSING status. You cannot apply other settings during this time. Settings take effect when the CDN resource transitions to ACTIVE.

  5. Purge the CDN resource cache.