> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bunny.net/llms.txt
> Use this file to discover all available pages before exploring further.

# Magento

> Integrate bunny.net CDN with your Magento store for faster page loads and optimized e-commerce performance.

This guide walks you through serving your Magento store's static and media files through Bunny CDN in four steps.

<Steps>
  <Step title="Create a Pull Zone">
    Log in to your [bunny.net dashboard](https://dash.bunny.net) and create a new Pull Zone with your Magento store as the origin URL. Match the protocol (HTTP or HTTPS) of your site exactly. For details, see [How to create your first Pull Zone](/cdn/quickstart).

    <Frame>
      <img src="https://mintcdn.com/bunnynet-cb9733c2/RilmGx6yE6wbeAYi/images/cdn/integrations/cms/magento-add-pull-zone.png?fit=max&auto=format&n=RilmGx6yE6wbeAYi&q=85&s=0b13dcf41fe28328ade24787406f169c" alt="Creating a Pull Zone for Magento" width="1140" height="224" data-path="images/cdn/integrations/cms/magento-add-pull-zone.png" />
    </Frame>
  </Step>

  <Step title="Add the required CORS headers">
    Open your Pull Zone's **Headers** settings and add the `html` and `json` extensions. This is required, otherwise your Magento admin interface won't work correctly.

    <Frame>
      <img src="https://mintcdn.com/bunnynet-cb9733c2/RilmGx6yE6wbeAYi/images/cdn/integrations/cms/magento-cors-headers.png?fit=max&auto=format&n=RilmGx6yE6wbeAYi&q=85&s=492ab2f568a690c7c31a50f515af81d9" alt="Adding CORS headers to the Pull Zone" width="1041" height="574" data-path="images/cdn/integrations/cms/magento-cors-headers.png" />
    </Frame>
  </Step>

  <Step title="Configure Magento to use the Pull Zone">
    Log in to your Magento admin panel and go to **Stores → Configuration → General → Web**.

    <Frame>
      <img src="https://mintcdn.com/bunnynet-cb9733c2/RilmGx6yE6wbeAYi/images/cdn/integrations/cms/magento-web-config.png?fit=max&auto=format&n=RilmGx6yE6wbeAYi&q=85&s=c6829f48d18b6ae7d66b5ebcad8f4b4e" alt="Magento Web configuration" width="1550" height="813" data-path="images/cdn/integrations/cms/magento-web-config.png" />
    </Frame>

    Open the **Base URLs** tab and enter your Pull Zone hostname in both **Base URL for Static View Files** and **Base URL for User Media Files**, including the `/static/` and `/media/` subfolders respectively.

    <Frame>
      <img src="https://mintcdn.com/bunnynet-cb9733c2/RilmGx6yE6wbeAYi/images/cdn/integrations/cms/magento-base-urls.png?fit=max&auto=format&n=RilmGx6yE6wbeAYi&q=85&s=5f1b4aebe51daf1eaaa89eb91656520c" alt="Setting the Base URLs" width="1505" height="848" data-path="images/cdn/integrations/cms/magento-base-urls.png" />
    </Frame>

    Repeat the same values in the **Base URLs (Secure)** section, using the `https://` version of the URL to avoid connectivity issues. Click **Save Config**.
  </Step>

  <Step title="Flush the Magento cache">
    Flush your Magento cache as prompted by the settings dashboard.
  </Step>
</Steps>

Your Magento store is now serving static and media files through Bunny CDN.
