← fakhar.tech · plain version
Fakhar Ul Islam
Developer. 8+ years building, debugging, optimizing and shipping for the web.
Most of the work starts with a site that's slow, broken, or both — and nobody knows why. I find out, fix it, and make sure it stays fixed. Frontend, backend, WordPress and WooCommerce, databases, servers, performance.
stack
WordPress · WooCommerce · PHP · MySQL · JavaScript · React · Next.js · Node.js · Shopify · REST APIs · Linux · Nginx · Redis · Cloudflare · AWS
And whatever the problem requires.
case files
The site that wouldn't load
Publisher · WordPress · ~40k posts
problem
Homepage TTFB was over 6 seconds and the host kept throwing 504s during traffic spikes. Two previous agencies had added a caching plugin and called it done.
investigation
- Profiled a cold request with Query Monitor + slow query log instead of guessing.
- Found 3.1 MB of autoloaded options — every request was loading dead plugin settings into memory.
- The homepage ran 11 separate WP_Query loops, four of them ordering by a meta value with no index.
- The caching plugin was bypassed for anyone with a tracking cookie. Which was everyone.
decision
Don't add another cache on top of a slow origin. Make the origin fast first, then cache the right things at the right layer.
build
- Cleaned autoload: 3.1 MB → 190 KB, with a migration that's safe to re-run.
- Collapsed homepage loops into two queries with a transient-backed fragment cache.
- Persistent object cache (Redis) + Cloudflare edge caching with proper bypass rules.
result
- TTFB: 6.2s → 0.21s
- Queries / page: 212 → 31
- 504s / week: ~40 → 0
WordPress · PHP 8 · MySQL · Redis · Cloudflare
The WooCommerce checkout problem
E-commerce · WooCommerce · 3 payment gateways
problem
Checkout abandonment jumped after a redesign. No errors in the logs, no complaints — just fewer orders.
investigation
- Replayed the checkout on throttled mobile. The place-order button took 4s to become interactive.
- A shipping plugin re-calculated rates on every keystroke via admin-ajax, each call ~900ms.
- Two gateways were loading their SDKs on every page of the site, not just checkout.
decision
Keep the plugins the business depends on, but control when they run. Rate calculation on intent, not on input.
build
- Debounced + cached shipping rate lookups by address hash.
- Conditional script loading: gateway SDKs only where the gateway is actually rendered.
- Moved a custom fee rule from a 'woocommerce_cart_calculate_fees' free-for-all into one tested class.
result
- Checkout interactive: 4.1s → 1.2s
- admin-ajax calls / checkout: 38 → 3
- Checkout completion: baseline → +18%
WooCommerce · PHP · JavaScript · Stripe · REST API
The 200K+ postmeta problem
Directory site · ACF · 200k+ meta rows per content type
problem
Filtering listings by three fields took 8+ seconds. Everything was stored in ACF fields, so every filter was a stack of JOINs on wp_postmeta.
investigation
- EXPLAIN showed full scans: meta_value isn't indexed and ACF stores numbers as strings.
- Each extra filter multiplied the rows examined — 3 filters meant ~1.2M rows touched.
decision
Keep ACF for editing. Stop using postmeta for querying. A typed, indexed lookup table kept in sync on save.
build
- Custom table with typed columns + composite indexes that match the actual filters.
- Sync on acf/save_post, plus a WP-CLI command to backfill and verify.
- Filter endpoint rewritten against the lookup table; WP_Query only hydrates the final IDs.
result
- Filter query: 8.4s → 38ms
- Rows examined: 1.2M → ~900
WordPress · ACF · MySQL · Custom tables · WP-CLI
The multilingual relationship problem
Corporate site · WPML · 6 languages
problem
Relationship fields pointed at the English versions of posts, so German pages linked to English case studies, and translations kept 'fixing' themselves back.
investigation
- ACF relationship fields stored raw post IDs; WPML's translation of those fields was set to 'copy'.
- Some content had been duplicated rather than translated, so there was no trid to map through.
decision
Store the relationship once, resolve it per language at render time, and repair the translation graph.
build
- Filter on acf/format_value that maps IDs through wpml_object_id with a fallback.
- Audit script to find orphaned duplicates and reconnect them to their translation groups.
result
- Wrong-language links: 1,140 → 0
- Editor steps per update: 6 languages → 1
WordPress · WPML · ACF · Custom post types
The server that needed saving
Agency · 12 WordPress sites on one box
problem
Load average sat above 20. One site getting traffic took the other eleven down with it. The proposed fix was a server three times the price.
investigation
- Every site shared one PHP-FPM pool with pm.max_children set to the default.
- Bots were hitting uncached search and xmlrpc.php around the clock.
- MariaDB was using the default buffer pool on a box with 16 GB of RAM.
decision
Isolate, then cache, then block. Buy hardware only if the numbers still say so afterwards.
build
- Per-site FPM pools with memory-based limits, so one site can't starve the others.
- Edge rules to challenge bad bots and cache anonymous traffic.
- Tuned InnoDB buffer pool + slow query log review for the worst offenders.
result
- Load average: 20+ → 1.4
- Server upgrade: 3× cost → not needed
Linux · Nginx · PHP-FPM · MariaDB · Redis · Cloudflare
The design that needed to convert
SaaS marketing site · Next.js + headless WordPress
problem
A good-looking landing page with a 5 MB hero video, a layout shift under the CTA and a lead form that lost submissions silently.
investigation
- CLS of 0.34 came from web fonts and a late-loading cookie banner pushing the CTA down.
- The form posted to a third-party script that failed on ad-blocked browsers without telling anyone.
decision
Keep the design intent, remove the cost. The page should feel the same and weigh a fifth.
build
- Poster image + on-intent video, font metric overrides, reserved space for the banner.
- Form posts to our own endpoint first, then fans out. Failures are visible and retried.
result
- CLS: 0.34 → 0.01
- Page weight: 5.6 MB → 0.9 MB
- Lost leads: unknown → 0
Next.js · React · WordPress REST · Tailwind
also shipped
- Custom WooCommerce B2B portal — Tiered pricing, quotes, account approvals (WooCommerce · PHP, 2025)
- Headless publishing stack — WordPress editorial, Next.js front, ISR (Next.js · WP REST, 2025)
- Booking engine plugin — Availability, deposits, calendar sync (PHP · MySQL · JS, 2024)
- Multisite migration — 38 sites consolidated, zero downtime (WordPress · WP-CLI, 2024)
- Shopify → WooCommerce move — Products, customers, orders, redirects (Shopify API · WooCommerce, 2023)
- Internal ops dashboard — Orders + fulfilment across 3 stores (React · Node.js, 2023)
contact
Have something difficult? hello@fakhar.tech
The fun version is at fakhar.tech. It knows it's a website.