October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run ScanOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
VGSources
Blog

How to Change the Apache Timeout Setting (TimeOut, ProxyTimeout, and RequestReadTimeout)

Apache has separate timeout directives for core I/O, proxied applications, and slow request reception. This guide explains how to choose, scope, test, and safely tune each one.
Length13 min Posted Quest giverVGSources Team
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Change Apache’s timeout in the active server or virtual-host configuration, using the directive that matches the delay: TimeOut for general Apache I/O, ProxyTimeout for waits on a proxied application server, and RequestReadTimeout for slow handshakes, request headers, or upload bodies. Test the configuration before reloading Apache, then reproduce the original request and check the relevant logs.

There is no single “Apache timeout” that controls every stage of a connection. Choosing the wrong directive can leave the original failure unchanged or weaken protection against connections that send data too slowly.

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Which Apache timeout do you need to change?

Start by identifying which side of the connection is waiting and what Apache is doing during the wait. The three directives below overlap in everyday language but control different operations.

Symptom or delay Directive What it controls Typical result when it expires
Apache waits for client reads or acknowledgements, CGI output, or an external filter TimeOut General Apache input/output waits The affected request or connection times out
Apache waits for a reverse-proxied application server ProxyTimeout Network waiting on the proxied request Apache stops waiting and returns a proxy timeout response
A client is slow during the TLS handshake, request headers, or request body RequestReadTimeout Receive-stage time limits and minimum data rates Apache sends a 408 Request Time-out

Use the most specific directive that describes the delay. Raising TimeOut will not necessarily make a slow upload acceptable, and changing ProxyTimeout will not extend the time allowed for a client to send headers.

TimeOut: Apache’s general I/O limit

Apache HTTP Server’s core documentation defines TimeOut as the length of time Apache waits for I/O in various circumstances. In Apache 2.4, the documented default is 60 seconds. The directive uses seconds and can be set in server configuration or virtual-host context:

TimeOut 120

The core timeout covers several kinds of waiting:

  • Waiting for a client TCP packet when Apache’s read buffer is empty.
  • Waiting for a client acknowledgement while Apache’s send buffer is full.
  • Waiting for output from CGI or mod_cgid programs.
  • Waiting for output from an external filter.

Use this setting when the delay is genuinely a general Apache I/O problem and no more narrowly targeted directive applies. A larger value gives slow operations more time, but it can also leave workers or connections occupied longer.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

ProxyTimeout: waiting for an upstream application

ProxyTimeout is supplied by mod_proxy for proxy requests. Its syntax is also a number of seconds, and its default is the current value of TimeOut:

ProxyTimeout 120

Place it in the server configuration or in the virtual host that performs the proxying. This is the appropriate setting when Apache is acting as a reverse proxy and the application server is slow or intermittently unresponsive. Apache can stop waiting and return a timeout instead of holding the request indefinitely.

This directive changes Apache’s network wait. It does not change the application server’s own execution, database, queue, or request timeout. If the upstream application terminates its work first, increasing Apache’s value cannot keep that work alive.

RequestReadTimeout: slow clients and uploads

The mod_reqtimeout module controls the receive stages of a request. It can set limits for the TLS handshake, request headers, and request body, and it can require a minimum incoming data rate:

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
RequestReadTimeout handshake=5 header=20-40,MinRate=500 body=20,MinRate=500

In Apache 2.4, the documented default is handshake=0 header=20-40,MinRate=500 body=20,MinRate=500. A value of 0 removes the limit for that stage. If a stage expires, Apache sends HTTP 408 Request Time-out.

The handshake stage is available beginning with Apache 2.4.39. The module itself is available in HTTPD 2.2.15 and later. Check the version and loaded modules on older installations before using handshake syntax.

Understand fixed and rate-based values

RequestReadTimeout values are not all simple fixed delays. The form you choose determines whether Apache allows extra time when data continues to arrive.

Fixed stage limit

A setting such as header=10 gives the entire header-reading stage a 10-second limit. If the client has not completed that stage when the limit is reached, Apache terminates the request.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Adaptive limit with a cap

A setting such as header=10-30,MinRate=500 starts with 10 seconds and allows the deadline to grow as data arrives at at least 500 bytes per second. The stage cannot extend beyond 30 seconds. This is useful when legitimate clients vary in latency but should not be allowed to send data arbitrarily slowly.

No limit for one stage

Set a stage to zero, for example body=0, to remove that stage’s mod_reqtimeout limit. Removing a receive limit should be a deliberate decision: a connection that sends very slowly can consume a worker or connection slot for a long time.

Choose global or virtual-host scope

All three directives can be set globally in server configuration or scoped to a particular virtual host. Global values affect every hosted site that inherits them. A virtual-host value is preferable when only one application has a slow workload, such as a large upload endpoint or a long-running proxy route.

Global configuration example

# In the server-wide Apache configuration
TimeOut 120

# For reverse-proxy requests handled by this server
ProxyTimeout 120

# Receive-stage limits
RequestReadTimeout header=20-40,MinRate=500 body=20,MinRate=500

One virtual host only

<VirtualHost *:443>
    ServerName example.test
    TimeOut 120
    ProxyPass        /app/ http://127.0.0.1:8080/
    ProxyPassReverse /app/ http://127.0.0.1:8080/
    ProxyTimeout 120
    RequestReadTimeout header=20-40,MinRate=500 body=60,MinRate=500
</VirtualHost>

The example illustrates scope, not a universal recommendation. Keep the timeout change as close as possible to the workload that needs it. A site-wide increase made only to accommodate one endpoint can expose unrelated sites to longer-held connections.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Check for an existing effective value

Before adding a directive, search the active configuration and included files for another occurrence. A later or more specific setting can determine the effective behavior. Also check whether the virtual host handling the request is the one you edited; a request reaching a different listener or host will not use the intended block.

Step-by-step: edit, test, and reload Apache

  1. Identify the active configuration. Use the configuration layout and service packaging for your operating system. Confirm which main file and included virtual-host files the running Apache instance loads.
  2. Classify the delay. Decide whether the wait is on client receive, general Apache I/O, CGI or filter output, or the connection to an upstream application. Select RequestReadTimeout, TimeOut, or ProxyTimeout accordingly.
  3. Back up the file you will edit. Preserve the previous working configuration so you can revert quickly if the test or reload fails.
  4. Change the narrowest applicable scope. Put a server-wide value in server context, or put a site-specific value inside the relevant <VirtualHost>. Use seconds and keep the directive spelling and capitalization exact.
  5. Run Apache’s configuration test. Use the command exposed by your package or service. Common installations provide apachectl configtest or httpd -t; Windows and vendor packages may use a different executable or service wrapper. Do not reload if the test reports a syntax or module error.
  6. Reload the service after a successful test. Reload is normally preferable because it applies configuration changes without unnecessarily terminating active connections. Use a full restart only when your deployment requires it or the service manager cannot perform a reload.
  7. Reproduce the original request. Test the same URL, upload size, client behavior, or proxied operation that previously failed. A generic homepage request will not exercise a slow upload or an upstream timeout.
  8. Inspect logs. Check Apache’s error and access logs and, for proxy requests, the upstream application logs. Confirm that the timeout stage you changed is the stage that now completes or expires.

Diagnose common failure patterns

A reverse-proxied request returns a timeout

First establish whether Apache is waiting for the upstream application or whether the application has already closed the connection. If Apache is the component waiting on the upstream network response, set ProxyTimeout in the proxying server or virtual host. If the application’s own timeout, worker limit, queue, or database call ends first, fix that upstream limit instead of only increasing Apache’s value.

Keep the proxy value long enough for the measured operation, but not so long that stalled upstream requests occupy all available capacity. Review both sides’ timestamps so you can see which component gives up first.

A client receives HTTP 408 during a handshake, header, or upload

A 408 from Apache points to a receive-stage limit. Inspect the RequestReadTimeout settings for the affected virtual host, including minimum-rate requirements. A fixed limit may be too short for the client’s network conditions; a rate-based range can allow additional time while data continues arriving at the configured rate.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Do not solve a slow-header problem by raising ProxyTimeout: the request has not reached the upstream application yet. Likewise, increasing TimeOut does not replace a deliberate mod_reqtimeout policy for slow clients.

CGI or filter output stops at the same interval

If the delayed operation is output from CGI, mod_cgid, or an external filter, examine TimeOut. Verify that the program is still running and producing output. Raising the value can allow a legitimate long operation to finish, but it also extends the period during which Apache resources remain committed to a request.

The change appears to have no effect

  • The edited file may not be included by the running instance.
  • The request may be routed to another virtual host or listener.
  • A later or more specific directive may override the value you changed.
  • The relevant module may not be loaded, particularly for RequestReadTimeout.
  • The upstream application or client may be enforcing its own shorter timeout.
  • Apache may not have been reloaded after the successful configuration test.

Use the logs and a configuration dump or service-specific inspection command to verify the effective virtual host and loaded modules rather than assuming the edited file controls the request.

Set a value from measured behavior

Apache’s documentation provides directive mechanics and defaults, not one best timeout for every workload. Choose a value from the slowest legitimate operation you need to support, then leave enough margin for normal network variation without making stalled connections effectively permanent.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • Measure the operation that is timing out. Record when Apache starts waiting, when the client or upstream sends data, and when either side closes the connection.
  • Separate normal slowness from a stuck process. A large upload arriving steadily is different from an application that has stopped responding.
  • Apply the increase only where needed. A virtual-host or route-specific policy limits the impact on other sites.
  • Consider concurrency. Higher values can keep workers, connection slots, and proxy capacity occupied for longer.
  • Retest under representative load. A setting that works for one request may still exhaust capacity when many clients hit the same slow path.

For receive stages, minimum-rate settings provide a way to distinguish a slow but progressing client from one that sends almost nothing. For upstream requests, coordinate Apache’s proxy timeout with the application’s own request and dependency timeouts so each layer fails in a predictable order.

Compare the directives by connection phase

Thinking in connection phases helps prevent trial-and-error changes. The client-to-Apache receive path includes the TLS handshake, headers, and request body; those are the stages governed by RequestReadTimeout. Once Apache is processing the request, general reads, writes, acknowledgements, CGI output, and external-filter output fall under TimeOut unless a more specific mechanism applies. When Apache forwards the request to another server, its wait for that proxied exchange is governed by ProxyTimeout, which otherwise inherits the TimeOut value.

Comparison point TimeOut ProxyTimeout RequestReadTimeout
Slow side Client or Apache-side I/O and program output Upstream application server Client sending request data
Timing model Fixed seconds Fixed seconds Fixed value or a minimum-rate range with a cap
Scope Server or virtual host Server or virtual host Server or virtual host
Typical failure Affected I/O operation times out Proxy request ends after Apache’s wait HTTP 408 Request Time-out

This distinction also explains why a timeout seen in a browser is not enough to identify the setting. The browser may display a generic error even though Apache logged a 408 from mod_reqtimeout, a proxy failure from mod_proxy, or a core I/O timeout. Match the log entry and elapsed interval to the connection phase before editing anything.

Practical configuration patterns

Need Configuration pattern Why this pattern fits
Allow a longer CGI or filter operation TimeOut 120 Targets the core I/O and program-output wait governed by Apache.
Give one reverse-proxy application two minutes to respond ProxyTimeout 120 inside that virtual host Extends the proxy wait without changing every hosted site.
Permit a progressing but slow upload RequestReadTimeout body=20-120,MinRate=500 Allows the body deadline to grow with incoming data while capping the stage.
Keep default-style protection for headers and body RequestReadTimeout header=20-40,MinRate=500 body=20,MinRate=500 Uses the Apache 2.4 documented default form for those stages.

The values in these examples are configuration examples, not guarantees that a particular application needs those durations. Validate them against observed request times and capacity.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Security and capacity trade-offs

Timeouts are resource controls as well as user-experience settings. Increasing TimeOut or ProxyTimeout can help a legitimate long-running request, but every extra second can keep a connection, worker, or upstream slot engaged. Removing a RequestReadTimeout stage limit eliminates a protection against clients that send request data extremely slowly.

Prefer a targeted virtual-host policy, a bounded rate-based receive rule, and an upstream application that exposes clear completion and cancellation behavior. After changing a value, watch connection counts, worker utilization, upstream queues, and timeout errors rather than judging success from one browser request.

What to verify after the reload

  • The configuration test completed successfully before the reload.
  • The service manager reported a successful reload or restart.
  • The request reached the intended virtual host.
  • The changed directive is active in the loaded configuration.
  • The original failure interval changed in the expected direction.
  • Apache and upstream logs identify the same timeout stage.
  • Resource usage remains acceptable when several slow requests run concurrently.

Once those checks agree, keep the value documented beside the virtual-host or route configuration, including why it was chosen and which workload requires it. That record prevents a future administrator from replacing a specific timeout with a broad, unexplained increase.

Additional troubleshooting questions

Why does a 504 not automatically mean ProxyTimeout?

A gateway or proxy error can be generated by several layers. Confirm in Apache’s error log that Apache was waiting for the upstream response and that the upstream had not already closed the connection. If the application, a database, or another intermediary has a shorter limit, changing Apache alone will not change the observed result.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Why can a larger TimeOut make an incident worse?

Each waiting request can retain a worker, connection slot, or other capacity. A broad increase may let more legitimate requests finish, but a burst of stalled clients can then occupy resources for longer. Scope the change narrowly and observe behavior with multiple concurrent requests.

Should a slow upload use a very large fixed body timeout?

Usually, first consider a minimum-rate rule with a maximum cap. A range such as body=20-120,MinRate=500 gives a client extra time while bytes continue arriving at the required rate, but still ends a connection that makes no useful progress. Removing the limit with body=0 should be reserved for a clearly understood case.

What if the installed Apache is older?

The mod_reqtimeout module is available in HTTPD 2.2.15 and later, while the handshake stage begins with 2.4.39. Older packages may reject newer syntax or omit the module, so verify the installed version and loaded modules before changing the directive.

Can one virtual host have a different timeout?

Yes. The core, proxy, and request-read directives support server configuration and virtual-host context. Put the value inside the relevant <VirtualHost> when only that site or application needs different behavior, and confirm that the request actually resolves to that host.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Frequently Asked Questions

How do I increase the general Apache timeout?

Set the core directive in server or virtual-host context, for example TimeOut 120. Apache 2.4 documents a 60-second default. Use it for general I/O, CGI output, or external-filter output, not for every kind of delay.

Why does Apache return a 504 while proxying?

Check whether Apache is waiting for the upstream application. If so, set ProxyTimeout in the proxying server or virtual host. Its default is the current TimeOut value. Also check the application’s own request, queue, database, and worker timeouts because those can expire first.

How do I allow a slow upload?

Use RequestReadTimeout for the request-body receive stage. A range such as body=20-120,MinRate=500 allows the deadline to grow while data arrives at the minimum rate, but caps the stage at 120 seconds. A stage that expires produces HTTP 408.

What is the difference between TimeOut, ProxyTimeout, and RequestReadTimeout?

TimeOut covers general Apache I/O and program output, ProxyTimeout covers Apache’s wait for a proxied application and otherwise inherits TimeOut, and RequestReadTimeout controls client handshake, header, and body receive stages with fixed or minimum-rate limits.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

How do I change the timeout for only one virtual host?

Place the appropriate directive inside that host’s <VirtualHost> block. Then run the package’s configuration test, reload Apache, and verify from logs that the request reached that host rather than another listener or virtual host.

Why did my timeout change have no effect?

The file may not be included, a later or more specific directive may win, the request may use another virtual host, the required module may be missing, Apache may not have been reloaded, or the client or upstream application may have its own shorter timeout. Check the effective configuration and logs.

The Bottom Line

Identify the connection phase first. Use TimeOut for general Apache I/O and CGI or filter output, ProxyTimeout for waits on a reverse-proxied application, and RequestReadTimeout for slow handshakes, headers, or uploads. Scope the change to the affected virtual host when possible, test the configuration, reload safely, and confirm the result in Apache and upstream logs. Choose a measured, bounded value so a legitimate slow operation can finish without allowing stalled connections to consume capacity indefinitely.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More quests from Patch Notes

  1. How to Set Up a RedM (RDR2) Server in 2026: License Key, txAdmin and server.cfg, Step by StepBlog11min
  2. Best RedM (RDR2) Server Hosting in 2026: Comparing Four Hosts on Slots, Memory and PriceBlog10min
  3. How to Host a Mindustry Server in 2026: server-release.jar, Port 6567 and the Commands That MatterBlog7min
Recommended PC Tool
Recommended PC Tool
Crashes, No Sound, or Screen Glitches?Free driver scan
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.