.WAR file extension

To open .WAR files on Windows, to run it: install and start a servlet container such as Apache Tomcat or Jetty, then deploy the .war (for Tomcat, place it in the host’s appBase/webapps directory, or use the Tomcat Manager application to deploy a WAR).

To open a .war file, either deploy it to a servlet container (such as Apache Tomcat or Jetty) to run the web app, or open it as an archive to inspect its contents (it is a Java archive). If you just want to look inside, treat it like a ZIP/JAR-style archive; if you want to use it, deploy it.

Last updated: June 12, 2026

Open on your device

Choose your operating system for a dedicated step-by-step opening guide.

How to open .WAR files

Use these platform-specific instructions to open .WAR files safely.

Windows

  1. To run it: install and start a servlet container such as Apache Tomcat or Jetty, then deploy the .war (for Tomcat, place it in the host’s appBase/webapps directory, or use the Tomcat Manager application to deploy a WAR).
  2. To inspect it: open the .war as an archive (it uses the Java archive/ZIP style) and look for folders like WEB-INF/classes and WEB-INF/lib.
Full Windows guide

Mac

  1. To run it: use a servlet container such as Apache Tomcat or Jetty and deploy the .war per the container’s deployment instructions (for example, placing it in the deployment directory).
  2. To inspect it: open it with an archive utility to view the standard web-app layout (WEB-INF, libraries under WEB-INF/lib, and optional WEB-INF/web.xml).
Full Mac guide

Linux

  1. To run it: deploy the .war to a servlet container such as Apache Tomcat or Jetty (for Tomcat this commonly means copying it into the appBase/webapps directory, or deploying via the Tomcat Manager app).
  2. To inspect it: open it as an archive and review the standard structure (WEB-INF/classes for compiled classes and WEB-INF/lib for JAR dependencies).
Full Linux guide

iOS

  1. iOS is not a practical platform to run a WAR directly; transfer the file to a desktop/server to deploy it on a servlet container, or open it only for inspection using an archive-capable app.
Full iOS guide

Android

  1. Android is not a practical platform to run a WAR directly; transfer the file to a desktop/server to deploy it on a servlet container, or open it only for inspection using an archive-capable app.
Full Android guide

Security notes

  • A WAR is server-deployed code: deploying an untrusted WAR to Tomcat/Jetty can execute attacker-controlled application logic within your server environment.
  • WARs commonly bundle third-party libraries in WEB-INF/lib; outdated or vulnerable dependencies inside a WAR can introduce security issues when deployed.
  • Be cautious with administrative deployment features (for example, Tomcat Manager’s WAR deployment): restrict access because uploading a WAR is effectively uploading code to run on the server.

Before you run downloaded code

These files usually need a runtime (Python, Node, Java, …). They are not classic “file viruses,” but untrusted code can still do serious harm if you execute it. Prefer official packages, verify publishers, and scan archives or sketchy downloads when you are unsure.

We may earn a commission when you use affiliate links. This supports our free file extension guides.

Can't open this file?

These are the most common causes and fixes when .WAR files fail to open.

Common reasons

  • Copied the WAR but the app does not deploy or start
  • Deployed application behaves differently than expected due to class/library loading
  • Tried to open the WAR like a normal app and nothing runs

Fix steps

  1. Inspect the WAR contents and verify the standard layout exists (for example: WEB-INF/classes for your compiled classes and WEB-INF/lib for dependency JARs).
  2. If you use a deployment descriptor, confirm WEB-INF/web.xml is present and correctly packaged.
  3. Redeploy using your container’s documented method (for example, place the WAR in Tomcat’s appBase/webapps or deploy via the Tomcat Manager app).

What is a .WAR file?

A WAR (Web Application Archive) is a distribution package for a Jakarta Servlet web application. It contains web resources at the archive root and application code and dependencies under WEB-INF (for example, WEB-INF/classes and WEB-INF/lib), plus optional deployment descriptors like WEB-INF/web.xml. Servlet containers use this structure to load the application and serve its content.

Background

WAR files are the standard deployable unit for servlet-based web applications. They bundle compiled Java classes, third-party libraries, static assets (HTML/CSS/JS/images), and configuration descriptors into one archive so a server can deploy the app consistently.

In common setups, you copy a .war into a server’s deployment directory (for example, a Tomcat host’s appBase) and the container deploys it, often by expanding it into a directory. Containers such as Tomcat and Jetty also support management/deployment workflows where a WAR is uploaded or placed in a specific deploy location.

Although a WAR can be inspected like a normal archive, it is not meant to be “opened” like a document. The practical use is deployment: the servlet container reads the standard directory layout (notably WEB-INF/classes, WEB-INF/lib, and WEB-INF/web.xml when present) to configure class loading and web application behavior.

Common MIME types: application/java-archive

Further reading

Authoritative resources for more details on the .WAR format.

Common .WAR issues

Copied the WAR but the app does not deploy or start

Servlet containers expect a specific web application structure inside the WAR. If required classes, libraries, or descriptors are missing or placed incorrectly, deployment can fail.

  1. Inspect the WAR contents and verify the standard layout exists (for example: WEB-INF/classes for your compiled classes and WEB-INF/lib for dependency JARs).
  2. If you use a deployment descriptor, confirm WEB-INF/web.xml is present and correctly packaged.
  3. Redeploy using your container’s documented method (for example, place the WAR in Tomcat’s appBase/webapps or deploy via the Tomcat Manager app).

Deployed application behaves differently than expected due to class/library loading

Servlet containers follow defined class loading and web application packaging rules. If you have duplicate libraries, incompatible versions, or misunderstand where classes should be placed, you can get runtime errors or unexpected behavior.

  1. Confirm libraries are packaged under WEB-INF/lib and your application classes under WEB-INF/classes (per common container deployment layouts).
  2. Remove duplicate or conflicting JARs in WEB-INF/lib and rebuild the WAR with a clean dependency set.
  3. Consult your container/spec documentation for how the container loads web application classes and resources.

Tried to open the WAR like a normal app and nothing runs

A WAR is a deployment package for a server-side web application; it is not an executable desktop application. It must be run by a servlet container.

  1. If your goal is to run the web app, deploy the WAR to a servlet container such as Tomcat or Jetty and access it through a web browser.
  2. If your goal is to inspect or extract contents, open it as an archive and review the files (WEB-INF, static assets, and libraries).

FAQ

Is a .war file just a .zip?

It is a Java archive-style package that can be inspected like an archive, but it has a specific web application layout (notably WEB-INF/classes and WEB-INF/lib) that servlet containers use for deployment.

How do I run a .war file?

Deploy it to a servlet container (for example Apache Tomcat or Jetty). The container reads the WAR and serves the web application.

What files should I expect inside a WAR?

Typically you will see web resources at the root, plus WEB-INF with compiled classes under WEB-INF/classes, libraries under WEB-INF/lib, and often a deployment descriptor at WEB-INF/web.xml.

What MIME type is commonly used for .war?

A commonly used registered media type for Java archives (often used for JAR/WAR) is application/java-archive.

Similar file extensions

Compare related formats in the same category to find the right tool faster.