elvismdev/claude-wordpress-skills/wp-performance-review
Claude Code and agent skill by elvismdev/claude-wordpress-skills
- community
Checking that the SKILL.md file is still in the repository.
WordPress performance code review and optimization analysis. Use when reviewing WordPress PHP code for performance issues, auditing themes/plugins for scalability, optimizing WP_Query, analyzing caching strategies, checking code before launch, or detecting anti-patterns, or when user mentions "performance review", "optimization audit", "slow WordPress", "slow queries", "high-traffic", "scale WordPress", "code review", "timeout", "500 error", "out of memory", or "site won't load". Detects anti-patterns in database queries, hooks, object caching, AJAX, and template loading.
Install
npx vskill@latest install elvismdev/claude-wordpress-skills/wp-performance-reviewSKILL.md
WordPress Performance Review Skill
Overview
Systematic performance code review for WordPress themes, plugins, and custom code. Core principle: Scan critical issues first (OOM, unbounded queries, cache bypass), then warnings, then optimizations. Report with line numbers and severity levels.
When to Use
Use when:
- Reviewing PR/code for WordPress theme or plugin
- User reports slow page loads, timeouts, or 500 errors
- Auditing before high-traffic event (launch, sale, viral moment)
- Optimizing WP_Query or database operations
- Investigating memory exhaustion or DB locks
Don't use for:
- Security-only audits (use wp-security-review when available)
- Gutenberg block development patterns (use wp-gutenberg-blocks when available)
- General PHP code review not specific to WordPress
Code Review Workflow
- Identify file type and apply relevant checks below
- Scan for critical patterns first (OOM, unbounded queries, cache bypass)
- Check warnings (inefficient but not catastrophic)
- Note optimizations (nice-to-have improvements)
- Report with line numbers using output format below
File-Type Specific Checks
Plugin/Theme PHP Files (functions.php, plugin.php, *.php)
Scan for:
query_posts()→ CRITICAL: Never use - breaks main queryposts_per_page.*-1ornumberposts.*-1→ CRITICAL: Unbounded querysession_start()→ CRITICAL: Bypasses page cacheadd_action.*init.*oradd_action.*wp_loaded→ Check if expensive code runs every requestupdate_optionoradd_optionin non-admin context → WARNING: DB writes on page loadwp_remote_getorwp_remote_postwithout caching → WARNING: Blocking HTTP
WP_Query / Database Code
Scan for:
- Missing
posts_per_pageargument → WARNING: Defaults to blog setting 'meta_query'with'value'comparisons → WARNING: Unindexed column scanpost__not_inwith large arrays → WARNING: Slow exclusionLIKE '%term%'(leading wildcard) → WARNING: Full table scan- Missing
no_found_rows => truewhen not paginating → INFO: Unnecessary count
AJAX Handlers (wp_ajax_*, REST endpoints)
Scan for:
admin-ajax.phpusage → INFO: Consider REST API instead- POST method for read operations → WARNING: Bypasses cache
setIntervalor polling patterns → CRITICAL: Self-DDoS risk- Missing nonce verification → Security issue (not performance, but flag it)
Template Files (*.php in theme)
Scan for:
get_template_partin loops → WARNING: Consider caching output- Database queries inside loops (N+1) → CRITICAL: Query multiplication
wp_remote_getin templates → WARNING: Blocks rendering
JavaScript Files
Scan for:
$.post(for read operations → WARNING: Use GET for cacheabilitysetInterval.*fetch\|ajax→ CRITICAL: Polling patternimport _ from 'lodash'→ WARNING: Full library import bloats bundle- Inline
<script>making AJAX calls on load → Check necessity
Block Editor / Gutenberg Files (block.json, *.js in blocks/)
Scan for:
- Many
registerBlockStyle()calls → WARNING: Each creates preview iframe wp_kses_post($content)in render callbacks → WARNING: Breaks InnerBlocks- Static blocks without
render_callback→ INFO: Consider dynamic for maintainability
Asset Registration (functions.php, *.php)
Scan for:
wp_enqueue_scriptwithout version → INFO: Cache busting issueswp_enqueue_scriptwithoutdefer/asyncstrategy → INFO: Blocks rendering- Missing
THEME_VERSIONconstant → INFO: Version management wp_enqueue_scriptwithout conditional check → WARNING: Assets load globally when only needed on specific pages
Transients & Options
Scan for:
set_transientwith dynamic keys (e.g.,user_{$id}) → WARNING: Table bloat without object cacheset_transientfor frequently-changing data → WARNING: Defeats caching purpose- Large data in transients on shared hosting → WARNING: DB bloat without object cache
WP-Cron
Scan for:
- Missing
DISABLE_WP_CRONconstant → INFO: Cron runs on page requests - Long-running cron callbacks (loops over all users/posts) → CRITICAL: Blocks cron queue
wp_schedule_eventwithout checking if already scheduled → WARNING: Duplicate schedules
Search Patterns for Quick Detection
Platform Context
Different hosting environments require different approaches:
Managed WordPress Hosts (WP Engine, Pantheon, Pressable, WordPress VIP, etc.):
- Often provide object caching out of the box
- May have platform-specific helper functions (e.g.,
wpcom_vip_*on VIP) - Check host documentation for recommended patterns
Self-Hosted / Standard Hosting:
- Implement object caching wrappers manually for expensive functions
- Consider Redis or Memcached plugins for persistent object cache
- More responsibility for caching layer configuration
Shared Hosting:
- Be extra cautious about unbounded queries and external HTTP
- Limited resources mean performance issues surface faster
- May lack persistent object cache entirely
Quick Reference: Critical Anti-Patterns
Database Queries
Hooks & Actions
PHP Code
Caching Issues
AJAX & External Requests
WP Cron
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationWarning, 47 of 100Marginal. 1 run. Evaluated 8 months ago.
Source
- SKILL.md in the repositoryCheckingskills/wp-performance-review/SKILL.md
Popularity
- Repository stars
- 121
- Repository forks
- 12
- 7-day trend score
- 24
Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 26 Mar 2026, 7 months ago.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/elvismdev/claude-wordpress-skills/wp-performance-review)