How to check the Tomcat version on Linux (and Windows)
Codemia Knowledge Hub ·
Run $CATALINA_HOME/bin/version.sh (or version.bat on Windows) to print the Tomcat version, build date and JVM details in one command. If you lack shell access, need the version of a running server, or want it from code, use the Manager app, the JAR manifest, or ServerInfo instead.
Method 1: version.sh or version.bat
This works on any Tomcat installation where you have shell access.
On Unix, Linux or macOS:
On Windows:
Typical output:
If CATALINA_HOME is not set, find the install directory. Common locations are /opt/tomcat, /usr/share/tomcat and /usr/local/tomcat. For package-managed installs:
Method 2: The Manager web application
Tomcat's Manager app shows the version alongside deployed applications.
- Open
http://your-server:8080/manager/htmlin a browser - Log in as a user with the
manager-guirole - The server version and JVM information appear at the top of the page
If Manager access is not set up, add a user in $CATALINA_HOME/conf/tomcat-users.xml:
For scripts and monitoring tools, there is a status endpoint:
It returns an HTML page with the version in the title. For machine-readable output, use the text endpoint. It needs a user with the manager-script role, and Tomcat recommends keeping that role off users that have manager-gui:
Method 3: MANIFEST.MF and ServerInfo.properties
Tomcat's JAR manifests carry version metadata, which helps when the server is not running or when you need to check a specific library.
Expected output:
You can also read the server info properties file packaged inside catalina.jar:
It contains:
Method 4: From Java code
To check the version at runtime inside a deployed application, use the ServerInfo utility class:
From a servlet, ServletContext also returns the server info:
This works on any servlet container, so it suits applications that may run on Tomcat, Jetty or others.
Method 5: Docker or process inspection
In containers, the version is usually in the image tag:
With only process-level access, look at the classpath or command-line arguments:
Comparison of methods
| Method | Requires Running Server | Shell Access Needed | Output Detail | Best For |
version.sh / version.bat | No | Yes | Full (version, JVM, OS) | Quick command-line check |
| Manager Application | Yes | No (browser) | Moderate | Remote servers with Manager enabled |
| MANIFEST.MF / ServerInfo.properties | No | Yes | Version string only | Offline verification, CI pipelines |
Programmatic (ServerInfo) | Yes | No | Full | Runtime checks within applications |
| Docker / process inspection | Depends | Varies | Image tag or classpath | Containerized deployments |
Tomcat versions and the specs they support
The version determines which security patches, Servlet API version and Java compatibility you have:
| Tomcat Version | Servlet Spec | JSP Spec | Java Minimum |
| 10.1.x | 6.0 | 3.1 | Java 11 |
| 10.0.x | 5.0 | 3.0 | Java 8 |
| 9.0.x | 4.0 | 2.3 | Java 8 |
| 8.5.x | 3.1 | 2.3 | Java 7 |
An outdated minor version within a major line is missing security fixes. Apache publishes CVEs against specific version ranges, so your exact version is the starting point for any vulnerability assessment.
Why a version check can mislead
- CATALINA_HOME not set.
version.shrelies on this variable and fails silently or prints an error without it. Set it, or run the script from the Tomcat installation directory. - Manager app not configured. Tomcat ships with no Manager users, so without a
manager-guiuser the Manager endpoint returns 401 or 403. - Installed vs running version. With several Tomcat installations on one machine,
version.shreports the one you point it at, which may not be the one serving traffic. Cross-check with the running process. - No catalina.jar manifest in embedded Tomcat. Repackaged or embedded distributions (such as Spring Boot's embedded Tomcat) may not include the
catalina.jarmanifest. Check the dependency version in your build tool instead. - Trusting the Server header. The
serverattribute inserver.xmlcan suppress or change theServerHTTP response header, so do not rely on it to identify the version.
Related reading
- Tracing versus Logging and how does log4net fit in?
- Tracing XML request/responses with JAX-WS
- Tradeoff between building own distributed system and using kubernetes to deploy my application
- Traefik Forward Authentication in k8s ingress controller
- Tomcat takes too much time to start - Java SecureRandom
- Tomcat threads vs Java threads
- Training a Neural Network in Python and deploying in C
- Trick to loop/autorefresh docker ps view like top/htop in bash
System design interview problems on this topic
- Design a Metrics Monitoring and Alerting System: solution and walkthrough
- Design a Distributed Tracing System: solution and walkthrough
- Design a Code Deployment System: solution and walkthrough
- Design GitHub Actions: solution and walkthrough

System Design Fundamentals
Build a strong foundation in designing scalable, reliable distributed systems.
View the courseSystem Design practice on Codemia
Work through 120+ system design problems with detailed solutions, from rate limiters to multi-region storage.