CDN Setup for 1C-Bitrix: Site Acceleration and Server Offload

When a 1C-Bitrix site feels slow for users in other regions and the server can't handle peak loads, we offer a solution — CDN setup. Our team takes on the entire cycle: provider selection, cache configuration, and Bitrix integration. We deliver the project turnkey with ongoing support, so your site runs fast and reliably for every visitor.

Our competencies:

Frequently Asked Questions

Setting up CDN for 1C-Bitrix: how to speed up the site and reduce server load

We often encounter a situation: an online store on Bitrix is slow in the regions, and the server is overwhelmed during peak loads. CDN (Content Delivery Network) solves both problems — it offloads the server from serving static content and reduces load time for remote users.

For example, for a store with an audience across Russia, the difference between Moscow and Vladivostok without CDN is 150–200 ms just for DNS and TCP. With a CDN Point of Presence in Vladivostok, static content is served in 5–15 ms.

Over 10 years, we have set up CDN for 50+ Bitrix projects — we share our experience. Without proper CDN configuration, even a powerful server won't help — the bottleneck remains at the network level.

Main problems that CDN solves

  • High latency for geographically remote users. Without CDN, requests go to a single server, which is critical for regions of Russia and the CIS.
  • Server overload from static content. According to our measurements, up to 80% of traffic on a typical store is images, CSS, and JS. Serving them via CDN reduces the load on the CPU and network of the main server by 50–70%.
  • Suboptimal caching. Typical Bitrix settings do not always correctly set Cache-Control for static content, which leads to extra requests.

How to choose a CDN provider for Bitrix?

When choosing a CDN, consider coverage, price, and integration. Here is a comparison of popular providers for Bitrix projects:

Provider Coverage in Russia Free plan Purge API SSL/TLS
Cloudflare Limited (Moscow, St. Petersburg) Yes (up to 100 GB) Yes Automatic
G-Core Labs Broad (10+ PoPs in Russia) No (trial period) Yes Let's Encrypt
Selectel CDN Good (Moscow, St. Petersburg, Novosibirsk) No Yes Own CA
KeyCDN Europe, Asia No Yes Let's Encrypt

For the Russian segment, G-Core Labs is optimal — low latency in all regions. Cloudflare is suitable for a start, but the free plan caches only static content, and the provider may filter traffic. Read more about CDN technology in external sources. Source: Wikipedia

Why doesn't CDN cache dynamic pages?

Dynamic pages (catalog, cart) with PHP processing are dangerous to cache on CDN — users would see other people's data. Therefore, only static resources are moved to CDN: files from /bitrix/cache/css/, /bitrix/js/, /upload/, fonts, icons.

The built-in module bitrix.cdn automatically rewrites the URLs of these resources to the CDN domain. If the module is not used — configure nginx sub_filter or a provider-side rule.

How to set up CDN for Bitrix: step-by-step instructions

  1. Choosing a provider and registration. Decide on a provider (we recommend G-Core Labs for Russia), create an account, get a CNAME or PTR record.
  2. DNS and SSL setup. Point a CNAME to the CDN domain (e.g., cdn.mysite.ru). The provider will automatically issue an SSL certificate.
  3. Configuring the CDN module in Bitrix. In the admin panel: Settings → Performance → CDN. Specify the CDN domain and path masks (/upload/*, /bitrix/cache/*). In the "Business" version and above, the module is built-in.
  4. Verification and cache invalidation. After setup, verify that static content is served from CDN (via curl -I). Set up automatic purge when templates are updated — use the provider's API via the OnAfterUpdateStaticFiles event.
  5. Speed monitoring. Compare load time before and after via PageSpeed or WebPageTest. Typical TTFB reduction for static content — from 200 ms to 20 ms.

Cache policy and invalidation

Correct Cache-Control for Bitrix static content: files with a hash in the name (generated by Bitrix during compression) — max-age=31536000, immutable. Files without a hash (style.css, script.js) — no more than a day with must-revalidate.

Cache invalidation when updating a template: use the provider's API to purge by URL or masks. This is automated via a deployment hook or the Bitrix event OnAfterUpdateStaticFiles.

Here is a table of recommended Cache-Control values for different file types:

File type Example path Cache-Control Comment
Hashed CSS/JS /bitrix/cache/css/*.css? max-age=31536000, immutable Hash changes on update
Unhashed /bitrix/js/main/core.js max-age=86400, must-revalidate Need to verify relevance
Images /upload/medialibrary/*.jpg max-age=86400 Resource-intensive file type

What is included in turnkey CDN setup

  • Audit of the current architecture and identification of bottlenecks.
  • Provider selection taking into account the audience geography.
  • DNS, SSL setup (automatic issuance).
  • Integration with the bitrix.cdn module or nginx sub_filter.
  • Cache policy configuration: Cache-Control with max-age and immutable for hashed files.
  • Automation of cache invalidation via the provider's API.
  • Performance testing (A/B test before/after).
  • Documentation and training for your team.

Case study from our practice

Our client is an online store with an audience in Russia and Kazakhstan. After connecting CDN (G-Core Labs), page load time for users from Kazakhstan decreased from 3.8 s to 1.4 s — solely due to static content. The PHP part was not changed.

Traffic savings on the main server amounted to 65%. This confirms that a properly configured CDN speeds up the site by 2.7 times without backend modifications.

Timelines and cost

Setting up CDN for Bitrix takes from 1 to 3 days depending on complexity (provider selection, DNS setup, module configuration, testing). Cost is calculated individually — it depends on the number of caching zones developed and automation.

Contact us — we will study your project and prepare an estimate. Get a consultation: write to us in chat or leave a request — we will help with CDN selection and turnkey setup.