skills/security-compliance/pci-dss-compliance/SKILL.md
Meet PCI-DSS payment security requirements by scoping your environment correctly, selecting the right SAQ, and implementing required controls
npx skillsauth add finsilabs/awesome-ecommerce-skills pci-dss-complianceInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
PCI-DSS (Payment Card Industry Data Security Standard) applies to any merchant that accepts card payments. The scope and complexity of your compliance obligations depend almost entirely on how card data flows through your systems. Merchants who use hosted payment forms (Shopify Payments, Stripe Checkout, PayPal hosted) can qualify for the simplest assessment (SAQ A, ~22 controls). Merchants who run custom payment pages face the most complex assessment (SAQ D, ~330 controls). The single most important PCI decision is: choose a payment method that minimizes your scope.
The most important decision in PCI compliance is how card data flows through your environment:
| Integration Method | SAQ Type | Approx. Controls | Who This Applies To | |-------------------|----------|-----------------|---------------------| | Fully hosted checkout (Shopify Payments, Stripe Checkout, PayPal hosted) | SAQ A | ~22 | Card data never touches your server; customer is redirected to the processor's payment page | | JavaScript tokenization on your page (Stripe Elements, Braintree Drop-in) | SAQ A-EP | ~191 | Card data is entered in an iframe on your page; your server never sees raw card numbers | | Your server touches card data | SAQ D | ~330 | Card data passes through your application server |
Recommendation: Always choose SAQ A when possible. Use Shopify Payments, Stripe Checkout, or a PayPal-hosted checkout. Moving from SAQ D to SAQ A reduces your annual compliance effort by ~85%.
Shopify is a PCI-DSS Level 1 Service Provider. When you use Shopify Payments or any payment gateway through Shopify's checkout, Shopify handles PCI compliance for the payment processing environment.
Your PCI scope as a Shopify merchant:
Completing your SAQ A on Shopify:
Key controls you still own:
WooCommerce itself is not PCI-compliant — compliance depends on your hosting, payment gateway, and implementation choices.
Minimize scope: use a hosted payment gateway:
Option A — Stripe Checkout (hosted redirect) → SAQ A
// Use WooCommerce Stripe Gateway in "Stripe Checkout" mode
// In WooCommerce → Settings → Payments → Stripe → Stripe Checkout: enable
// Customer is redirected to stripe.com for payment; SAQ A applies
Option B — Stripe Elements in WooCommerce → SAQ A-EP
WooCommerce hosting requirements for SAQ A-EP: Your web hosting must meet minimum PCI requirements:
What to verify for WooCommerce PCI:
BigCommerce is a PCI-DSS Level 1 certified platform. Using BigCommerce's hosted checkout and supported payment gateways puts you in SAQ A territory.
Completing compliance on BigCommerce:
Key BigCommerce settings:
For custom storefronts, your PCI scope is determined by how you integrate payment processing. Use Stripe Elements or Braintree Drop-in UI to stay in SAQ A-EP territory.
SAQ A-EP implementation with Stripe Elements:
// Client-side: Stripe handles card data in an iframe — your code never sees card numbers
const stripe = await loadStripe(process.env.NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY!);
const elements = stripe.elements({ clientSecret });
const paymentElement = elements.create('payment');
paymentElement.mount('#payment-element');
// On submit — Stripe creates a PaymentMethod on their servers
const { error, paymentIntent } = await stripe.confirmPayment({
elements,
confirmParams: { return_url: `${window.location.origin}/order-confirmation` },
});
// Your server never receives a card number — only a paymentMethodId or paymentIntentId
Key controls for SAQ A-EP (custom storefronts):
# Requirement 4: TLS 1.2+ only, strong cipher suites
ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256;
add_header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload" always;
Content Security Policy for payment pages (Requirement 6.4.3 in PCI-DSS v4.0):
// Strict CSP on checkout pages — only authorized scripts allowed
const csp = [
`default-src 'self'`,
`script-src 'self' 'nonce-${nonce}' https://js.stripe.com`,
`frame-src https://js.stripe.com https://hooks.stripe.com`,
`connect-src 'self' https://api.stripe.com`,
`object-src 'none'`,
].join('; ');
response.headers.set('Content-Security-Policy', csp);
Audit logging (Requirement 10):
// Log every authentication event, admin action, and access to payment data
interface AuditEntry {
timestamp: string;
userId: string;
userIp: string;
action: string;
resource: string;
outcome: 'success' | 'failure';
}
// Ship logs to an immutable store: CloudWatch Logs, Datadog, or S3 with Object Lock
// Requirement 10.7: Retain logs for 12 months; 3 months immediately available
PCI-DSS controls checklist:
| Requirement | Key Engineering Task | |-------------|---------------------| | Req 3: Protect stored data | No raw card numbers stored; use Stripe/Braintree tokens only | | Req 4: Encrypt transmissions | TLS 1.2+; HSTS headers; no mixed content | | Req 6: Secure development | Dependency scanning (npm audit, Snyk) in CI; SAST; script inventory on payment pages | | Req 7–8: Access control | Role-based access; unique IDs; MFA for admin; password policy | | Req 10: Logging | All auth events, admin actions, and CDE access logged with user ID, timestamp, IP | | Req 11: Vulnerability management | Quarterly external scans by ASV; annual penetration test |
| Problem | Solution |
|---------|----------|
| Selected SAQ A but using Stripe Elements | Stripe Elements (JavaScript on your page) is SAQ A-EP, not SAQ A; only a fully hosted redirect (Stripe Checkout) qualifies for SAQ A |
| Debug logging enabled in production captures payment data | Disable WordPress/WooCommerce debug logging in production; WC_DEBUG and WP_DEBUG must be false |
| TLS 1.0/1.1 still enabled on load balancer | Verify with nmap --script ssl-enum-ciphers -p 443 yourstore.com; disable TLS 1.0/1.1 in your load balancer and CDN |
| Third-party scripts on checkout page not inventoried | PCI v4.0 requires a documented inventory; audit with browser dev tools; remove non-essential scripts from payment pages |
| No incident response plan | PCI Requirement 12.10.1 requires a documented IR plan tested annually; create a basic one even if you've never had an incident |
tools
Let shoppers save products to a wishlist, share it with friends, and get notified when saved items come back in stock or drop in price
development
Build a themeable storefront with design tokens and CSS custom properties that supports white-labeling, multi-brand variants, and dark mode
development
Speed up product discovery with instant search suggestions, fuzzy typo matching, and category-aware results powered by Algolia or Elasticsearch
development
Build a mobile-first storefront with thumb-friendly navigation, sticky add-to-cart buttons, and touch-optimized components for high mobile conversion