MODX pdoTools Configuration and Site Optimization
We configure pdoTools for MODX websites, replacing standard snippets with high-performance alternatives to reduce page generation time from seconds to milliseconds. Our team installs, configures, and tunes pdoResources, pdoMenu, pdoPage, pdoParser, and related tools, delivering measurable speed improvements on sites of any size. We have optimized 10+ MODX sites and regularly cut page generation time by 85 to 95 percent. Clients see lower server costs and better Core Web Vitals scores immediately after deployment.
Standard MODX snippets such as getResources and Wayfinder use the xPDO ORM layer, which generates many small database queries per page. On a page with 20 resources and a navigation menu, this can mean 50 to 100 database queries. pdoTools replaces these with optimized PDO-based queries, typically reducing query count by 90 percent.
What's Included in Our pdoTools Optimization Setup
We deliver pdoTools configuration as a turnkey service. The scope covers:
- Install pdoTools via MODX Package Manager
- Replace standard getResources, getPage, and Wayfinder calls with pdoResources, pdoPage, and pdoMenu
- Configure TV loading via
&prepareTVs=1to replace N+1 queries with single JOIN queries - Enable per-component caching with unique cache keys that include filter parameters
- Set up pdoParser to replace the standard MODX parser for 20–40% faster tag processing
- Configure pdoSitemap for fast sitemap generation on large sites
- Profile before-and-after performance to document the improvement
How Does pdoTools Speed Up MODX?
Standard getResources makes one database query per resource to load TV values. A list of 20 products with 3 TVs each means 60 additional queries just for TV data. pdoResources loads all TV values with a single JOIN query regardless of list size.
pdoMenu handles navigation even more efficiently. The full site navigation tree, including active state detection and class assignments, loads in one or two queries instead of the recursive queries that Wayfinder generates.
After switching a typical 50-page MODX site from standard snippets to pdoTools, our clients see page generation times drop from 800–1500ms to 80–200ms. For sites with heavy traffic this translates directly to lower server costs and better Core Web Vitals scores.
pdoResources Configuration
[[pdoResources? &parents=`5` &resources=`-10` &showHidden=`0` &sortby=`menuindex` &sortdir=`ASC` &limit=`10` &includeTVs=`product_price,product_image` &prepareTVs=`1` &processTVs=`1` &tpl=`productCard` &tvPrefix=`` &cache=`1` &cacheTime=`1800` ]] The &prepareTVs=1 parameter loads all TV values with a single JOIN query. The &cache=1 and &cacheTime=1800 parameters cache the rendered output for 30 minutes, bypassing database queries entirely on cached requests.
pdoPage for Pagination
[[!pdoPage? &element=`pdoResources` &parents=`5` &limit=`12` &tpl=`productCard` &includeTVs=`product_price,product_image` &pageNavVar=`page.nav` &cacheKey=`catalog_[[+GET.page:default=1]]` ]] [[!+page.nav]] pdoPage generates pagination navigation automatically and handles the page GET parameter. The cache key includes the current page number so each pagination page has its own cache entry.
pdoMenu for Site Navigation
[[pdoMenu? &startId=`0` &level=`2` &sortby=`menuindex` &tplOuter=`@INLINE <ul class="nav">[[+wrapper]]</ul>` &tpl=`@INLINE <li class="[[+classes]]"><a href="[[+link]]">[[+menutitle]]</a>[[+wrapper]]</li>` &tplInner=`@INLINE <ul class="nav__sub">[[+wrapper]]</ul>` &hereClass=`active` &parentClass=`has-children` &cache=`1` &cacheTime=`3600` ]] Menu caching is critical. Navigation is among the most expensive MODX queries, as it must traverse the resource tree on every page. With &cache=1 and &cacheTime=3600, the menu HTML renders once per hour per cache variation.
How Is pdoTools Optimization Delivered?
- Profile the current site with a baseline measurement of queries per page and page generation time
- Identify the highest-impact snippet replacements
- Replace standard snippets with pdoTools equivalents, one template at a time
- Verify template rendering matches the original output
- Enable caching and verify cache key uniqueness for filtered views
| Scope | Timeline |
|---|---|
| Replacing standard snippets on a 20–50 page site | 3–5 working hours |
| Full optimization with caching and pdoParser setup | 4–8 working hours |
| Large catalog site with complex TV setup and filters | 1–2 working days |
Our team has experience with 10+ MODX projects across e-commerce, news portals, and corporate sites. Contact us to discuss your site structure, and we will estimate the potential performance gain before starting work.
How We Deliver
We start with a baseline profile. We identify the slowest page loads. We prioritize by impact. We replace snippets one at a time. We verify output matches the original. We enable caching. We confirm the new baseline. We document all changes for your team.







