Created by WOW - Wielka Optymalizacja WordPressa, Bartek Miś
A comprehensive performance optimization guide for WordPress development, designed for AI agents and LLMs assisting developers.
Install the skill in Claude Code:
npx add-skill bartekmis/wordpress-performance-best-practisesOnce installed, Claude will automatically apply these performance guidelines when working with WordPress code.
This project provides a curated set of performance rules for WordPress development based on:
- WordPress VIP Coding Standards
- WordPress Coding Standards
- 10up Engineering Best Practices
- Official WordPress Developer Documentation
If you're an AI agent or LLM, use the compiled AGENTS.md file which contains all rules in a single, optimized format.
wordpress-performance-best-practices/
├── AGENTS.md # Compiled output for AI agents
├── SKILL.md # Skill definition for agent integration
├── README.md # This file
├── metadata.json # Project metadata
├── rules/ # Individual rule files
│ ├── _sections.md # Section definitions
│ ├── _template.md # Template for new rules
│ ├── db-*.md # Database optimization rules
│ ├── cache-*.md # Caching strategy rules
│ ├── asset-*.md # Asset management rules
│ ├── theme-*.md # Theme performance rules
│ ├── plugin-*.md # Plugin architecture rules
│ ├── media-*.md # Media optimization rules
│ ├── api-*.md # API and AJAX rules
│ └── advanced-*.md # Advanced pattern rules
└── build/ # Build tools
├── src/ # TypeScript source
└── package.json # Build dependencies
| # | Section | Prefix | Impact | Description |
|---|---|---|---|---|
| 1 | Database Optimization | db- |
CRITICAL | Query optimization, prepared statements, indexing |
| 2 | Caching Strategies | cache- |
CRITICAL | Object cache, transients, page caching |
| 3 | Asset Management | asset- |
HIGH | Script/style loading, defer/async |
| 4 | Theme Performance | theme- |
HIGH | Template optimization, loop performance |
| 5 | Plugin Architecture | plugin- |
MEDIUM-HIGH | Conditional loading, hooks, autoloading |
| 6 | Media Optimization | media- |
MEDIUM | Image handling, lazy loading |
| 7 | API and AJAX | api- |
MEDIUM | REST API, admin-ajax optimization |
| 8 | Advanced Patterns | advanced- |
LOW-MEDIUM | Autoload, cron, memory management |
Browse individual rule files in the rules/ directory for detailed explanations and examples.
- Include
AGENTS.mdin your context - Or use
SKILL.mdfor agent framework integration
cd build
npm install
npm run buildThis compiles all rules into AGENTS.md.
- Create a new rule file in
rules/using_template.mdas a guide - Use the appropriate prefix for your section (e.g.,
db-for database rules) - Include both incorrect and correct code examples
- Run the build to regenerate
AGENTS.md - Submit a pull request
Each rule follows this structure:
---
title: Rule Title
impact: CRITICAL | HIGH | MEDIUM-HIGH | MEDIUM | LOW-MEDIUM | LOW
impactDescription: Optional quantified improvement
tags: comma, separated, tags
---
## Rule Title
Explanation of the rule.
**Incorrect (description):**
\`\`\`php
// Bad code
\`\`\`
**Correct (description):**
\`\`\`php
// Good code
\`\`\`
Reference: [Link](url)MIT License - Feel free to use this in your projects and AI agents.