Shopify handles billions of dollars in transactions annually and invests heavily in platform security. But Shopify's security and your store's security are not the same thing. The platform may be hardened, but your theme, third-party apps, and operational practices introduce risks that Shopify cannot control. Here is how to take ownership of your store's security.
The Third-Party App Risk
The Shopify App Store contains thousands of apps. When you install an app, you grant it access to your store data — customer records, order history, product information, and sometimes payment data. Many apps also inject JavaScript into your storefront, where they can read everything a customer types.
Before installing any app:
- Review the permissions it requests — does a reviews app really need access to all orders?
- Check the developer's reputation, review count, and last update date
- Read the privacy policy to understand where your customer data is sent
- Regularly audit installed apps and remove any you no longer actively use
Unused apps are attack surface. A compromised app vendor can push a malicious update that runs code in your store. Remove apps you do not need immediately.
JavaScript Supply Chain: The Magecart Threat
Magecart attacks target e-commerce sites by injecting malicious JavaScript that silently copies payment card details as customers type them. These attacks have affected British Airways, Ticketmaster, Newegg, and thousands of smaller Shopify merchants through compromised third-party scripts.
On Shopify, the attack surface is primarily through:
- Third-party apps that inject JavaScript into your theme
- Custom theme code that loads external scripts without integrity checks
- Compromised CDN resources loaded by your theme
Mitigation steps:
- Add Subresource Integrity (SRI) attributes to any external scripts you control:
<script src="..." integrity="sha384-..." crossorigin="anonymous"></script> - Minimize the number of third-party JavaScript dependencies
- Regularly review your theme's
theme.liquidandcheckout.liquidfor unexpected script tags - Monitor your Shopify payments for unusual chargebacks that might indicate skimming
Security Headers via Cloudflare or Netlify
Shopify does not allow direct control of HTTP response headers, which limits your ability to set security headers like Content-Security-Policy, X-Frame-Options, and Referrer-Policy natively. The standard workaround is to proxy your store through Cloudflare.
With Cloudflare's Transform Rules (available on all plans), you can add security headers to every response:
X-Frame-Options: SAMEORIGIN— prevents clickjackingX-Content-Type-Options: nosniff— prevents MIME sniffingReferrer-Policy: strict-origin-when-cross-origin— limits referrer data leakagePermissions-Policy— restricts access to browser APIs
A strict Content-Security-Policy is very difficult to implement on Shopify because the platform itself loads many third-party resources. Start with a report-only CSP to understand what your store actually loads before enforcing it.
SSL Certificate Monitoring
Shopify manages SSL certificates for *.myshopify.com domains. If you use a custom domain, the certificate is managed via Shopify's partnership with DigiCert. Despite this, custom domain certificates do occasionally fail to renew — especially if DNS settings change during a domain migration.
Set up monitoring for your SSL certificate expiry date. A certificate that expires takes your store offline and displays browser warnings that destroy customer trust instantly. Tools like Shieldome can monitor certificate validity and alert you before expiry. At minimum, set a calendar reminder to check your cert 30 days before the expiry date.
Customer Data Protection
Under GDPR, CCPA, and similar regulations, your store is responsible for the personal data you collect — even if Shopify stores it on your behalf. Practical steps:
- Review your privacy policy and ensure it accurately describes what data you collect and why
- Enable Shopify's built-in customer data export and deletion features to handle DSAR requests
- Minimize data collection — only ask for information you actually need for order fulfillment
- If you use email marketing, ensure you have explicit consent records and honor unsubscribe requests immediately
PCI-DSS Compliance on Shopify
Shopify is a PCI-DSS Level 1 certified service provider — the highest possible certification. This means that if you use Shopify Payments and do not store card data yourself, you benefit from Shopify's compliance and your own compliance scope is dramatically reduced.
Your PCI-DSS obligations as a Shopify merchant:
- Complete the SAQ A (Self-Assessment Questionnaire A) annually — the simplest SAQ, designed for merchants that fully outsource payment processing
- Never store card numbers, CVVs, or full track data anywhere — not in notes, emails, or custom databases
- Use only Shopify Payments or a PCI-compliant payment gateway (Stripe, Braintree) — avoid custom payment forms that send card data to your own server
- Keep your Shopify admin account secured with two-factor authentication
If you use a custom checkout or accept card data through any non-Shopify mechanism, your PCI scope expands significantly and you may need a Qualified Security Assessor (QSA) for a full audit.
Two-Factor Authentication for Admin Accounts
Your Shopify admin account has access to all customer data, order history, and financial reports. A compromised admin account is a catastrophic breach. Enable two-factor authentication for every staff account that has admin access.
In your Shopify admin: Settings → Users and permissions → Security → Require two-step authentication. This enforces 2FA for all staff accounts, not just your own.
Use an authenticator app (Google Authenticator, Authy, 1Password) rather than SMS-based 2FA — SMS codes are vulnerable to SIM swapping attacks.
Shopify Partner App Review
If you work with a Shopify Partner agency or developer, review the collaborator access they have been granted. Partners can have full admin access, including access to customer data and financial reports. Revoke collaborator access immediately when the engagement ends.
Audit collaborator access at: Settings → Users and permissions → Collaborators.
Ongoing Security Monitoring
Security is not a one-time configuration — it is an ongoing practice. Run an external scan of your Shopify storefront monthly to check for: missing security headers, SSL certificate health, exposed sensitive files, and new JavaScript resources that were not there last month. Automated scanners catch configuration drift that manual reviews miss.