Technology

Website Slow Only at Certain Hours? Diagnose CPU, IO and MySQL Issues

Noticing that your website is fast most of the day, but becomes painfully slow at specific hours? This pattern is rarely random. In real hosting environments, time-based slowdowns almost always point to resource bottlenecks: saturated CPU, overloaded disk IO, or a MySQL database that struggles under peak load. The challenge is separating guesswork (“our hosting is bad”) from data (“CPU is 100% every night between 20:00–22:00” or “IOwait spikes during backup windows”).

In this article, we’ll walk through how we at dchost.com typically approach these cases on both shared hosting and VPS servers. You’ll learn how to recognize whether your bottleneck is CPU, disk IO or MySQL, which tools and panels to look at, and what to change in your application or hosting plan. We’ll stay practical: concrete metrics, screenshots you can imagine from cPanel and SSH, and a checklist you can follow next time your site slows down at the same hour again.

Why Your Website Is Only Slow at Certain Hours

When a website is consistently slow 24/7, causes are usually structural: underpowered hosting, heavy code, missing caching, large images, or poor database design. When the site is fast most of the day but slow at clearly defined periods, you are almost always seeing a time-bound resource contention problem.

Common real-world patterns we see:

  • Peak visitor traffic: Lunch or evening peaks where CPU and MySQL connections spike simultaneously.
  • Shared hosting “neighbor noise”: Other accounts on the same server run backups, imports or cron jobs at predictable times.
  • Your own scheduled tasks: WordPress/WooCommerce crons, report generation, feeds, or synchronizations stacked at the same minute every hour.
  • Backup and antivirus windows: Full-server backups and malware scans stressing disk IO and CPU for 30–60 minutes.
  • External systems: Payment gateways, shipping APIs or CRM integrations that respond slowly under their own peak load.

To fix the issue properly, you need to answer three questions:

  1. Exactly when is the site slow?
  2. Which resource hits its limit at those times (CPU, IO, MySQL, memory, connections)?
  3. What workload is causing that spike (visitors, bots, backups, crons, imports)?

Once you map the timing to a resource and a workload, the right solution (optimize, spread out tasks, cache better, or upgrade) becomes much clearer.

Step 1 – Confirm the Slowdown Pattern with Real Measurements

Before jumping into server metrics, confirm the pattern from the browser side. Time-based slowdowns can easily be masked by caching, or misinterpreted if you only test occasionally.

Use proper speed test tools at different hours

Run tests at different times of the day from tools such as GTmetrix, PageSpeed Insights or WebPageTest. We explain how to interpret these tools in detail in our guide on how to properly test your website speed.

Track at least:

  • TTFB (Time To First Byte) – server response time. If this spikes only during slow hours, the issue is server-side.
  • Fully loaded time – how long until all assets are loaded.
  • Number of requests – whether your page weight changes or it’s purely a server capacity issue.

If front-end assets and total size are similar but TTFB jumps from, say, 200 ms to 2–3 seconds in peak hours, you are most likely facing CPU/IO/MySQL constraints. You can also dive deeper into server-side causes in our article on fixing high TTFB on WordPress and PHP sites.

Correlate slow times with your business and tasks

Make a simple timeline:

  • When do visitors usually peak? (analytics)
  • When do you run imports, exports, feed generation or reports?
  • When do your email campaigns land in inboxes and drive traffic?
  • When are your backup jobs scheduled (site or external tools)?

Write down these time ranges and compare them with observed slow periods. This makes the next steps (checking hosting and VPS metrics) much more meaningful.

Step 2 – Check CPU and PHP Bottlenecks on Shared Hosting and VPS

CPU is the first place we look when a website slows down at defined hours. On PHP-based sites (WordPress, WooCommerce, Laravel, custom PHP) every request involves PHP, and PHP is CPU-heavy under load.

On shared hosting: read your control panel resource graphs

If you use cPanel or a similar panel, your account usually has a “Resource Usage” or “CPU and Concurrent Connections” section. We’ve explained those graphs in detail in our article understanding cPanel resource limits and the ‘Resource Limit Reached’ error.

During or right after a slowdown, open that page and look for:

  • CPU usage – is it flatlining near 100% of your allocated limit?
  • Entry Processes (EP) – number of concurrent processes. If this hits the limit, new requests queue or get 503 errors.
  • Physical memory (RAM) – high RAM + high CPU suggests PHP is working very hard.
  • Faults / “Resource limit reached” events – clear indicator you’re hitting caps during that hour.

If the graphs show CPU or EP pegged exactly during your slow hours and normal otherwise, you’ve found a strong candidate: CPU saturation at peak.

On a VPS: use SSH tools like top/htop

On a VPS or dedicated server, log in via SSH and run:

top

or, if installed,

htop

Key things to look at while the slowdown is happening:

  • Overall CPU usage – is it consistently above 80–90%?
  • Per-core usage – one core at 100% can bottleneck even if others are idle (common with PHP-FPM misconfiguration).
  • Top CPU-consuming processes – typically php-fpm, lsphp, Apache/nginx workers, or MySQL.

If PHP-FPM is your web engine, you can tune its process limits. We covered this in-depth for WordPress/WooCommerce in our guide on PHP-FPM settings (pm, pm.max_children, pm.max_requests). The principles are the same for most PHP apps: too few workers cause queues and high TTFB, too many cause CPU and memory exhaustion.

What CPU saturation usually looks like from the website

Typical browser-side symptoms of CPU issues in peak hours:

  • Initial page response (TTFB) is slow, but once HTML arrives, static assets load quickly.
  • Admin pages (e.g. WordPress dashboard) are much slower than cached front pages.
  • Intermittent 503 or 508 errors during stress while the rest of the day is fine.

Quick CPU-related mitigations on shared hosting

On a shared plan, you cannot directly add more CPU cores, but you can reduce peak CPU usage:

  • Enable and configure caching: For WordPress, use a full-page cache plugin or LiteSpeed Cache if your host supports it.
  • Disable or limit heavy plugins: Page builders, analytics, security scanners, related posts and visual sliders can be expensive.
  • Offload cron jobs: Disable WP-Cron and run a real cron at a lower frequency, as described in our guide on using real cron jobs instead of wp-cron.
  • Optimize PHP limits: Avoid excessively high memory_limit or max_execution_time that let slow scripts run forever. We have a dedicated article on choosing the right PHP memory_limit and execution time.

If you frequently hit CPU or EP caps despite optimizations, it may be time to upgrade your shared plan or move to a VPS. We discuss server-side signals in our article on 9 hosting upgrade signals based on server metrics.

Quick CPU mitigations on a VPS

  • Tune PHP-FPM workers to match CPU and RAM.
  • Enable OPcache so PHP doesn’t recompile scripts on every request.
  • Add a reverse proxy cache such as nginx fastcgi_cache or LiteSpeed full-page caching for dynamic sites.
  • Review cron schedule and spread heavy jobs across off-peak minutes instead of running them all at 00:00.

Step 3 – Detect Disk IO (IOwait) and Storage Bottlenecks

Even if CPU looks fine, your server can be blocked waiting for disk operations: reading PHP files, database data, logs, or backups. This appears as high IOwait and sluggish performance especially under heavy writes (backups, imports).

On shared hosting: IO graphs and backup windows

In cPanel-like dashboards, you’ll often see an IO Usage or Disk IO graph for your account. Look for:

  • Spikes in IO usage (near your limit) during the exact time your website becomes slow.
  • “Resource limit reached” events mentioning IO or faults tagged as I/O-related.

Some time-based IO slowdowns are caused by server-wide tasks like backups and malware scans. These may not show under your own account’s IO metrics, but you’ll notice that slowdowns always coincide with a specific time window (e.g., 02:00–02:20 every night). In that case:

  • Ask support whether full-server backups or scans run in that window.
  • If yes, see whether schedules can be shifted, or if your account can be moved to a less busy node.

On our shared infrastructure at dchost.com, we plan backup windows and IO budgets carefully, but for IO-heavy sites (e.g. large WooCommerce stores), we still often recommend moving to NVMe VPS plans so you have guaranteed disk performance.

On a VPS: check IOwait and disk activity

On Linux, run:

top

and look at the CPU line. The wa value is IOwait: the percentage of time the CPU is idle but waiting for disk.

  • If wa is consistently high (e.g. > 20%) during slow hours while overall CPU is not maxed, you likely have a disk bottleneck.

Then use tools like:

iostat -x 1 10
vmstat 1 10
iotop -o

to see which devices and processes are hitting disk hardest. Typical culprits:

  • Database server flushing large InnoDB buffers or rewriting indexes.
  • Backup tools reading the entire filesystem.
  • Log files growing very quickly (debug logging enabled in production).
  • Image or video processing jobs.

Fixing IO-related slowdowns

Depending on what you find, options include:

  • Reduce write amplification: Turn off verbose debug logging on production; rotate logs; avoid writing massive temporary files.
  • Reschedule backups to truly off-peak hours, and ensure incremental backups are used where possible.
  • Move heavy processing jobs off the web server (e.g. media conversions to a worker VPS).
  • Upgrade storage to faster disks (NVMe over SATA) or move to a plan with higher IOPS limits.

If you’re setting up or benchmarking a new VPS, we also recommend simple IO tests during non-peak and peak periods. Our guide on benchmarking CPU, disk and network performance on a new VPS walks through practical commands you can reuse later when diagnosing slowdowns.

Step 4 – Investigate MySQL/MariaDB Bottlenecks

For database-backed sites (WordPress, PrestaShop, Magento, custom apps), MySQL/MariaDB is often the real bottleneck behind time-based slowdowns. As traffic grows and data accumulates, queries that were fine at launch become slow.

Symptoms of a database bottleneck

From the user’s perspective, MySQL issues look similar to CPU problems, but there are subtle clues:

  • The whole site (including cached pages) seems fine, but specific actions become slow: search, filtering, cart/checkout, dashboards.
  • Some pages with many queries (e.g. product listing with multiple filters) are much slower in peak hours than in the morning.
  • Short bursts of database errors or timeouts, especially under concurrent users.

On shared hosting: what you can see

On shared hosting, you usually have limited access to MySQL internals, but you can still:

  • Look for MySQL-related errors in your application logs (e.g. “too many connections”, lock wait timeouts).
  • Use plugins or admin tools to measure number of queries per page and detect very slow queries.
  • Ask support whether the database server load correlates with your slow periods.

For WooCommerce and other busy stores, we’ve seen many sites hit limits not because of raw CPU, but because of unoptimized queries. Our article on WooCommerce MySQL/InnoDB tuning shows what we look at in practice; most concepts apply to other PHP apps as well.

On a VPS: use the slow query log and basic MySQL metrics

On a VPS with root or MySQL access, enable the slow query log:

SET GLOBAL slow_query_log = 1;
SET GLOBAL long_query_time = 1;  -- or 0.5 for finer detail

Then, during or after slow hours, inspect the log (often /var/log/mysql/slow.log or similar) to see:

  • Which queries are taking > 1 second.
  • Which tables are frequently scanned without indexes.
  • Whether specific pages or modules cause repeated slow queries.

You can also run:

SHOW PROCESSLIST;

to see live queries during peak. If many connections are stuck in “Locked” or “Copying to tmp table” states, or the number of concurrent connections grows until MySQL refuses new ones, you have a clear database bottleneck.

Database-related fixes that reduce peak-hour slowdowns

  • Optimize slow queries: Add missing indexes, rewrite suboptimal SQL, or adjust ORM-generated queries to reduce joins and sorts.
  • Use caching layers: Object caches (Redis/Memcached) and full-page caching dramatically cut database load for repeated page views.
  • Clean up bloat: Old sessions, transient options, logs and revisions can slow down queries that scan large tables.
  • Increase MySQL resources: On a VPS, tune innodb_buffer_pool_size, max_connections, and related settings so MySQL can keep more data in memory and handle concurrency better.
  • Split heavy reporting: Run big reports or exports on a replicated database or at off-peak hours, not during your main sales window.

When MySQL becomes the dominant bottleneck and simple tuning is not enough, separating the database from the web server or scaling vertically/clustered may be necessary. We discuss such architectures in our guides on when to separate database and application servers and on high-availability database setups.

Step 5 – Look Beyond the Server: Traffic Spikes, Bots and External Services

Not every time-based slowdown is purely internal. Some are triggered by patterns in traffic or third-party services.

Legitimate traffic peaks vs. abusive traffic

Use your analytics and server logs to see what’s happening during slow hours:

  • Are page views or concurrent users significantly higher? That’s healthy growth, and your infrastructure must be sized accordingly.
  • Are specific countries, IP ranges or user agents spiking? Could be bots, scrapers or even early-stage DDoS attempts.

If you suspect bots are overloading your site at certain hours (e.g. aggressive crawlers after you publish news), rate limiting and WAF rules can help. We’ve shared practical WAF strategies in our guide on combining WAF and bot protection on real hosting stacks.

Third-party APIs and services

Some slowness originates outside your hosting:

  • Payment gateways that respond slowly during local business peak hours.
  • Shipping and ERP APIs that get overloaded when many merchants sync inventory at the same time.
  • External marketing and personalization scripts added to the page.

To diagnose this, compare:

  • Server-side TTFB (from speed tools or browser dev tools Network tab) – if this is fine but the page still feels slow, external scripts may be the culprit.
  • Application logs – measure how long API calls take and add timeouts or fallbacks.

In general, do not block your entire page render waiting for slow third-party services. Use asynchronous loading on the front-end, and on the back-end, use reasonable timeouts and background jobs where possible.

Step 6 – When It’s Time to Scale Up or Change Architecture

After you’ve optimized code, caching, cron schedules, and database queries, you might still see CPU, IO or MySQL hitting hard limits during predictable peaks. At that point, the question is not “What’s broken?” but “Is this plan still sufficient for our traffic and business?”

Signs your current plan is simply too small

  • Resource graphs consistently show CPU or IO usage near the limit during your normal, expected peak hours.
  • Even well-optimized pages and queries are slower in peak traffic compared to off-peak.
  • You’ve implemented caching correctly, but logins, carts and checkouts still struggle with modest concurrency.

In those cases, options with dchost.com typically include:

  • Upgrading shared hosting to a plan with more CPU/IO allowance for small/medium sites.
  • Moving to an NVMe VPS for dedicated CPU, RAM and high IOPS disk, ideal for growing e-commerce or SaaS apps.
  • Planning dedicated or clustered setups for high-traffic stores, news sites or mission-critical applications.

We also recommend monitoring and alerting on your VPS so that you can see trends before they turn into outages. Our guide on VPS monitoring and alerts with Prometheus, Grafana and Uptime Kuma is a good starting point if you manage your own servers.

Practical Troubleshooting Checklist for Time-Based Slowdowns

Here is a concise, repeatable checklist you can follow next time your site is slow only at certain hours:

  1. Record the time window
    • Note exact start/end times when the site feels slow.
    • Check if this repeats daily/weekly or aligns with marketing campaigns.
  2. Measure from the outside
    • Run speed tests (TTFB, fully loaded time) during slow and normal hours.
    • Use dev tools to see if TTFB or front-end assets are the main issue.
  3. Check hosting panel metrics (shared hosting)
    • CPU, IO, EP, RAM graphs for the exact slow period.
    • Any “Resource limit reached” errors (CPU/IO/EP).
  4. Check server metrics (VPS/dedicated)
    • top/htop for CPU, IOwait, per-process usage.
    • iostat and iotop for disk-intensive tasks.
    • MySQL status and slow query log for database hotspots.
  5. Correlate with workloads
    • Cron jobs (WordPress cron, imports, reports).
    • Backups, security scans, cache warmups.
    • Traffic spikes, bots, external API calls.
  6. Apply targeted fixes
    • Enable/strengthen caching and reduce heavy plugins.
    • Spread out cron jobs and backup tasks.
    • Optimize the worst database queries and add indexes.
    • Rate limit abusive traffic and tune WAF rules.
  7. Re-test and re-monitor
    • Repeat speed tests and review metrics in the next peak window.
    • If you still hit hard limits despite optimizations, plan a resource upgrade.

If you are on shared hosting and frequently see “resource limit reached”, our dedicated article on avoiding the resource limit reached error on shared hosting covers practical steps to stay within your limits without harming performance.

Bringing It All Together (and How dchost.com Can Help)

When your website is slow only at certain hours, the real goal is to stop guessing. With a bit of structured detective work—timing, external speed tests, control panel graphs, and VPS metrics—you can usually pinpoint whether the bottleneck is CPU, disk IO, MySQL, or something external like bots or APIs. Once that link is clear, the right mix of caching, scheduling changes, query optimization and, where necessary, capacity upgrades becomes straightforward instead of stressful.

At dchost.com, we work with both shared hosting and VPS customers who run into these exact patterns as their traffic and business grow. If you’re not sure whether your issue is configuration, code or simply lack of resources, our team can review your metrics, explain what’s happening in plain language, and suggest a realistic path: from small optimizations on your current plan to moving up to an NVMe VPS or dedicated setup when it’s truly justified. If your site keeps slowing down at the same times every day, that’s your infrastructure asking for attention—reach out, share your observations, and we’ll help you turn those noisy peak hours back into calm, predictable performance.

Frequently Asked Questions

When a website is fast most of the day but slow in clearly defined time windows, it usually means one of your server resources is hitting a limit only during those hours. Common causes are CPU saturation from peak visitor traffic, disk IO spikes caused by backups or virus scans, and MySQL bottlenecks from slow queries under load. Sometimes external factors like email campaigns, bot traffic or slow third‑party APIs line up with those hours as well. By correlating slow periods with control panel graphs, VPS metrics and your cron or backup schedule, you can identify which resource is constrained and what workload is triggering it.

On shared hosting, check your control panel’s Resource Usage page during or right after the slowdown and look for CPU usage flatlining near 100% and many “resource limit reached” events. Entry Processes (EP) hitting their limit is another CPU-related hint, as it indicates too many concurrent PHP processes. On a VPS, log in via SSH and run top or htop while the site is slow. If overall CPU or one core is close to 100% and PHP-FPM, Apache or lsphp processes are at the top of the list, CPU is your bottleneck. When CPU is the issue, caching more aggressively, trimming heavy plugins and tuning PHP-FPM worker counts can significantly reduce peak-time slowdowns.

IOwait is the percentage of time your CPU is idle but stuck waiting for disk read/write operations to complete. When IOwait is high, your server isn’t really calculating—it’s queuing work while the disk catches up. This often happens during nightly backups, antivirus scans, large imports or heavy logging. During those periods, your site may feel slow even if CPU usage is not at 100%. On a VPS, you can see IOwait in tools like top, vmstat and iostat. If IOwait spikes exactly when your website slows down, you may need to reschedule backups, reduce unnecessary disk writes or move to faster storage (for example NVMe-based VPS plans) to keep performance stable.

Database bottlenecks usually show up as actions involving dynamic data becoming slow under concurrent users: product searches, filtering, dashboards, cart and checkout. If your homepage and cached pages are fine but these operations drag during peak traffic, MySQL is a strong suspect. On shared hosting, look for MySQL timeout or connection errors in logs and use admin tools to see how many queries a page runs. On a VPS, enable the slow query log and watch SHOW PROCESSLIST during slow periods. Many long‑running queries, locked rows or a rising number of concurrent connections point to database overload. Adding indexes, optimizing queries and using caching layers can dramatically reduce peak‑time MySQL pressure.

You should consider upgrading when metrics show that you’re consistently hitting CPU, IO or MySQL limits during perfectly normal business peaks, even after reasonable optimizations. Signs include resource graphs flatlined at their limits, frequent “resource limit reached” events, and users still experiencing slow checkout or dashboard pages despite caching, lighter plugins and query tuning. At that stage, the issue is less about misconfiguration and more about capacity: your current shared plan or small VPS cannot comfortably handle your real-world load. Moving to a higher shared tier, an NVMe VPS, or a separate database server through a provider like dchost.com gives you more headroom so your site remains responsive during growth and campaigns.