Disable Csp

yireo/magento2-disable-csp

Disables Content Security Policy (CSP) in Magento 2. Simplifies disabling CSP for shops where it's not required.

No errors foundPHPStan level 9Build passingSemVer compliant
Supported Magento versions
2.4.9
License
OSL-3.0
Categories
Performance & Optimization, Security & Compliance

179,448 installs★ 22 stars8,290 downloads/monthLatest: v1.0.3Released 2025-04-17

composer require yireo/magento2-disable-csp

README

Reproduced from the package’s own README, under its own license, as of 2026-10-31. Links and images point back at the source repository.

Yireo DisableCsp

Magento version PHP version License Latest Version

For shops that don't need CSP to be enabled, this module offers a quick solution. Just install and enable the module and you're done.

Technically, it replaces the default implementation of Magento\Csp\Api\CspRendererInterface with a dummy.

Usage

composer require yireo/magento2-disable-csp
bin/magento module:enable Yireo_DisableCsp

Remark

The magento/module-csp package is still necessary and should not be removed via composer replace.

Alternatives

Current status

Static Tests Unit Tests Integration Tests Playwright DI Compilation

← All packages from yireo