For the complete documentation index, see llms.txt. This page is also available as Markdown.

Path & Extension Based Rate Limiting

Apply request rate limits and IP whitelist exceptions to traffic matching specific URL paths or file extensions using Page Rules.

Path & Extension Based Rate Limiting allows you to apply request rate limits to traffic matching specific URL paths and/or file extensions, such as /api, /login, .pdf, or .jpg.

This provides granular control over specific endpoints or file types without applying the same rate limit to all traffic.

Path & Extension Based Rate Limiting is available under Page Rules for Small, Large, and Dynamic CDN Resources. It is Off by default and must be explicitly enabled for each Page Rule.

Resource-level Rate Limiting must be enabled before a Rate Limiting configuration in a Page Rule can take effect.

How Rate Limiting Works in Page Rules

Path & Extension Based Rate Limiting uses the same continuous rate enforcement behavior as resource-level Rate Limiting but applies it only to traffic matching the Page Rule.

The configured limit is evaluated continuously as a request rate rather than as a fixed request count that resets at the end of the selected time period.

For example, a configuration of 100 requests per minute is distributed over time and enforced continuously. It does not allow all 100 requests to be sent at once at any point during the minute.

When the permitted request rate is exceeded, the configured Burst Mode determines how temporary traffic spikes are handled.

IP Whitelist

Each Page Rule can define its own IP Whitelist for Rate Limiting.

Requests from whitelisted IP addresses are excluded from the Rate Limit configured for that Page Rule. Other requests matching the Page Rule remain subject to the configured rate limit.

IP whitelists are configured independently for each Page Rule. This allows different paths or endpoints to exclude different trusted IP addresses from Rate Limiting.

Burst Modes

You can select one of the following Burst Modes:

  • None — Enforces the configured request rate without additional burst capacity.

  • Burst — Allows requests above the configured rate within the defined burst capacity. Requests within this capacity may be delayed and processed according to the configured rate.

  • Burst + No Delay — Allows requests within the defined burst capacity to pass immediately without delay.

Burst capacity does not increase the configured request rate. It provides temporary tolerance for short traffic spikes above the normal rate.

When requests exceed the permitted rate and available burst capacity, they are blocked with an HTTP 429 Too Many Requests response.

Configuration Fields

Field
Description

Path

Defines the URL path matched by the Page Rule, such as /api/login.

File Extensions

Defines the file extensions matched by the Page Rule, such as .html, .jpg, or .pdf.

Rate Limiting

Enables or disables Rate Limiting for the Page Rule.

Request Limit

Defines the request rate applied to traffic matching the Page Rule.

Per

Defines the time unit for the request rate: Per Second or Per Minute.

Burst Mode

Determines how temporary traffic spikes above the configured request rate are handled: None, Burst, or Burst + No Delay.

Burst Value

Defines the burst capacity when Burst or Burst + No Delay is selected.

IP Whitelist

Enables or disables the IP whitelist for the Page Rule's Rate Limiting configuration.

If the resource's default Cache Type is dynamic or edge, you must explicitly define the same Cache Type in the Page Rule when applying Path & Extension Based Rate Limiting. Otherwise, caching for that path or extension falls back to origin, and response behavior relies on origin headers.

Configure Path & Extension Based Rate Limiting

1

Access Page Rules

Navigate to the Page Rules tab in your CDN Resource in the Medianova Control Panel.

2

Click Add Rule

Select Add Rule to create a new Page Rule.

3

Define the Traffic

Define the traffic that the Page Rule should match:

  • Enter a Path, such as /login.

  • Enter one or more File Extensions, such as .jpg or .pdf, when required.

4

Select Rate Limiting

Select Rate Limiting from the Page Rule settings.

5

Enable Rate Limiting

Enable the Rate Limiting toggle.

6

Configure the Rate

Configure the request rate:

  • Request Limit — Select the request limit.

  • Per — Select Per Second or Per Minute.

  • Burst Mode — Select None, Burst, or Burst + No Delay.

  • Burst Value — Define the burst capacity when Burst or Burst + No Delay is selected.

If the resource's default Cache Type is dynamic or edge, explicitly add the same Cache Type to the Page Rule.

7

Configure the IP Whitelist

To exclude trusted IP addresses from Rate Limiting for this Page Rule:

  1. Enable IP Whitelist.

  2. Enter an IP address in the Add IP... field.

  3. Select + to add the IP address.

  4. Repeat the process to add additional IP addresses when required.

Added addresses appear under Whitelisted IPs.

Whitelisted IP addresses bypass the Rate Limit configured for this Page Rule. Other matching requests remain subject to the configured rate limit.

8

Save the Rule

Select Save Rule to apply the Page Rule configuration.

With None, the configured request rate is enforced without additional burst capacity. Select Burst or Burst + No Delay when the targeted traffic needs to tolerate short spikes above the configured request rate.

Page Rules are processed in order, from top to bottom. If multiple rules match the same request, only the first matching rule is applied. Place more specific rules before broader rules that could match the same traffic.

Example

The following example applies Rate Limiting to /api/v2 while excluding a trusted service IP from the Page Rule's rate limit:

In this example, the configured rate of 100 requests per minute is enforced continuously for requests matching /api/v2.

With Burst + No Delay, temporary traffic above the configured rate can use the defined burst capacity, and requests within that capacity can pass immediately without delay.

Requests from 203.0.113.5 bypass the Rate Limit configured for this Page Rule.

The Burst Value is not added to the Request Limit as a separate request quota. Burst capacity provides temporary tolerance above the configured rate, and the number of requests accepted during a traffic spike can vary depending on request timing.

Use Cases

  • Protect API endpoints — Apply specific request rates to paths such as /api/auth, /api/login, or /checkout.

  • Exclude trusted service traffic — Whitelist trusted service IP addresses that must access a rate-limited endpoint without being subject to the Page Rule's request rate.

  • Control file downloads — Apply rate limits to file extensions such as .jpg, .pdf, or .zip.

  • Combine path and extension matching — Apply Rate Limiting to specific file types under paths such as /reports or /downloads.

  • Control access to static resources — Apply request rates to resources under /media/ or /static/.

  • Reduce automated traffic — Apply rate limits to product, category, search, or filter endpoints that may receive excessive automated requests.

Limitations

  • Path & Extension Based Rate Limiting is Off by default and must be enabled separately for each Page Rule.

  • Resource-level Rate Limiting must be enabled before Rate Limiting in a Page Rule can take effect.

  • The supported Request Limit range is 100–1000.

  • Requests exceeding the permitted rate and available burst capacity are blocked with an HTTP 429 Too Many Requests response.

Last updated

Was this helpful?