Sobre os arquivos WAR
Web Application Archive
Pacote Java EE para aplicações web (Servlets, JSP). Variante de JAR específica para deployment em servlet containers (Tomcat, Jetty).
Família
Archives & Compressed
Extensão
.war
Tipo MIME
application/java-archive
Pode ser usado como
COMO NASCEU O
FORMATO WAR.
WAR — Web Application Archive — is the JAR variant for Java web applications. When Sun shipped Servlet 2.2 specification in 1999, WAR became the standard deployment unit for Java EE web apps: a ZIP archive containing compiled classes (in /WEB-INF/classes/), libraries (/WEB-INF/lib/), static resources (HTML, CSS, JS at the root), and a /WEB-INF/web.xml deployment descriptor. Drop the .war into a servlet container like Tomcat, Jetty, or GlassFish and the app deploys automatically.
For 20+ years WAR has been the enterprise Java deployment unit. Every Spring MVC app, every JSF/JSP app, every Java REST API hosted on a traditional application server shipped as .war. The newer Spring Boot trend of fat-JARs has partially replaced WAR (Spring Boot bundles an embedded Tomcat and ships as .jar), but WAR remains the dominant deployment format for legacy Java EE and any classical servlet container.
CURIOSIDADES E
FATOS INTERESSANTES.
A .war is literally a ZIP — extract it and browse the exact directory structure that lives inside your Tomcat webapps/ folder.
The /WEB-INF folder inside every WAR is private to the server — clients cannot fetch its files via HTTP.
Spring Boot "embedded Tomcat" fat-JARs replaced many WAR deployments, but WAR remains dominant in enterprise Java EE.
An EAR (Enterprise ARchive) is a further wrapper that bundles multiple WARs and JARs — the enterprise deployment container.
GlassFish, WebSphere, WebLogic, and JBoss EAP all accept .war deployments identically — the format is truly portable.
VANTAGENS E
LIMITAÇÕES.
Vantagens
- Standard Java EE deployment unit since 1999.
- ZIP-based — introspectable with any unzip tool.
- Auto-deployment in Tomcat, Jetty, GlassFish, and every Java servlet container.
- Well-defined web.xml deployment descriptor.
- Compatible with any JVM.
Limitações
- Requires a servlet container runtime — heavier than a self-contained fat-JAR.
- Spring Boot fat-JARs reduce WAR's relevance in new projects.
- Not containerized — Docker-era deployment prefers JAR + embedded server.
- File sizes balloon with dependency libraries in /WEB-INF/lib/.
Tamanhos típicos de arquivo
Simple Servlet app
500 KB - 5 MB
Typical Spring MVC app with libs
20-100 MB
Large enterprise WAR
200-800 MB
Especificações técnicas
- MIME type
- application/java-archive
- Extension
- .war
- Container
- ZIP (JAR format)
- Required descriptor
- WEB-INF/web.xml
- Runtime
- Servlet container (Tomcat, Jetty, GlassFish, etc.)
CONVERTER A PARTIR DE
WAR
Casos de uso comuns
Java EE deployment, web server apps
Formatos relacionados
Comparativos populares
WAR vs ZIP
Diferenças, tamanho de arquivo e quando escolher cada formato.
WAR vs 7Z
Diferenças, tamanho de arquivo e quando escolher cada formato.
WAR vs TAR
Diferenças, tamanho de arquivo e quando escolher cada formato.
WAR vs GZ
Diferenças, tamanho de arquivo e quando escolher cada formato.
WAR vs BZ2
Diferenças, tamanho de arquivo e quando escolher cada formato.
WAR vs XZ
Diferenças, tamanho de arquivo e quando escolher cada formato.
Conversões populares de WAR
Os destinos mais procurados ao converter arquivos WAR.
Perguntas frequentes sobre WAR
Perguntas frequentes
WAR (Web aplicativo Archive) is an archive formato used to bundle multiple arquivos e folders em a single comprimido file. The archive preserves the directory structure e tipicamente reduces total size via compressão. WAR sits no archives & comprimido family e has specific strengths around compressão ratio, speed, ou plataforma support.
7-Zip, WinRAR, The Unarchiver (macOS), e the built-in archive utilities no Windows e macOS abrir most WAR files. para command-line extraction, 7z, unar, ou the formato-specific tool handles WAR cleanly. If your extractor does not recognise WAR, converter to ZIP first — ZIP opens on every operating system sem extra software.
Upload the WAR to KaijuConverter e pick ZIP, 7Z, TAR.GZ, ou RAR como o target. Our pipeline extracts the original archive e re-compresses the contents em the target formato. arquivo permissions, timestamps, e directory structure are preserved where both formatoos support them.
Depends no goal. ZIP is the universal baseline — every OS extracts it out of the box. formatoos like 7Z ou TAR.GZ compress better mas require specific ferramentas. WAR may win on compressão ratio, password support, ou OS integration para specific workflows; ZIP wins on raw compatibilidade.