Understand JMeter Non HTTP response code and Non HTTP response message: connection, SSL, and client exceptions. Symptom, causes, and how to fix samples.
Non HTTP response code in JMeter
Section titled โNon HTTP response code in JMeterโSymptom
Section titled โSymptomโView Results Tree or the results file shows:
- Response code:
Non HTTP response code: java.net.โฆ(or similar) - Response message:
Non HTTP response message: โฆ
There is no standard HTTP status such as 200, 401, or 503. The sample is failed because the HTTP client threw an exception before a normal status line was available.
Common nested types:
java.net.ConnectExceptionjava.net.SocketException/ connection resetjavax.net.ssl.SSLHandshakeExceptionjava.net.SocketTimeoutExceptionjava.net.UnknownHostException
Common causes
Section titled โCommon causesโ| Cause | Typical nested message |
|---|---|
| Cannot connect | ConnectException, connection refused/timed out |
| DNS failure | UnknownHostException |
| TLS trust / handshake | SSLHandshakeException, PKIX path building failed |
| Peer closed socket | Connection reset, SocketException, socket closed |
| Read/connect timeout | SocketTimeoutException |
| Wrong proxy settings | Connect or tunnel failures when a proxy is required |
Official debugging still starts with one thread and View Results Tree (best practices recommend Tree only while scripting).
Fix (ordered)
Section titled โFix (ordered)โ-
Read the full message after
Non HTTP response code:/message:- treat the Java exception as the real error. -
Route to the dedicated playbook:
-
Confirm protocol/host/port via HTTP Request Defaults.
-
Check connect and response timeouts on the HTTP Request sampler.
-
Disable corporate proxy surprises: if the OS proxy is set but the SUT is internal, configure JMeter proxy fields deliberately or clear them.
-
Re-run CLI with logging:
Terminal window jmeter -n -t plan.jmx -l results.jtl -j jmeter.log -
After connect works, add assertions so HTTP 5xx pages are not mistaken for success (API guide).
Related tools and topics
Section titled โRelated tools and topicsโ| Resource | Use when |
|---|---|
| ConnectException | Refused / timed out connect |
| SSLHandshakeException | Certificate and TLS failures |
| Dashboard report | Aggregate error rates after CLI |
| Troubleshooting overview | Broader checklist |
Frequently asked questions
Section titled โFrequently asked questionsโIs Non HTTP response code a real HTTP status?
Section titled โIs Non HTTP response code a real HTTP status?โNo. It is JMeterโs way of saying the sampler failed with a client-side exception instead of an HTTP status line.
Can Non HTTP errors appear only under load?
Section titled โCan Non HTTP errors appear only under load?โYes. Connection limits, TLS session issues, or server overload can surface as resets and timeouts only at higher concurrency. Still fix connectivity for one thread first.
Do these count in error percentage?
Section titled โDo these count in error percentage?โYes. Failed samples increase error % on the HTML dashboard and in listeners.