OWASP WebGoat Install Guide: Docker, Linux, Windows & Login
OWASP WebGoat Install Guide for Docker, Linux & Windows
Official-source setup • Updated August 5, 2026

OWASP WebGoat Install Guide for Docker, Linux, Windows and Login

Run WebGoat as a controlled local training lab. This guide uses the official Docker image, loopback-only port bindings, a pinned release option, current Linux and Windows setup paths, account registration, WebWolf, and practical troubleshooting.

OWASP WebGoat is a deliberately insecure Java application for legal, controlled security education. The easiest setup is the official Docker image because it includes WebGoat and WebWolf without requiring a local Java build environment. Keep both ports on loopback, create a disposable account, and never expose the lab to the public internet.

Fast answer: run the pinned Docker command below, wait for the startup log, open http://127.0.0.1:8080/WebGoat/, register a local account, and open WebWolf only when a lesson requires it.

Install OWASP WebGoat with Docker in a Few Minutes

The official project publishes a combined image that serves WebGoat on port 8080 and WebWolf on port 9090. The host-side addresses below are explicitly bound to 127.0.0.1, so another computer cannot reach the lab through the machine's normal network address.

Use a pinned, localhost-only start command

The tagged image makes a workshop more repeatable than an unpinned latest image. Set TZ to the host's IANA timezone because selected JWT and time-sensitive lessons depend on matching time settings.

Open WebGoat

Command tools ready

Pinned WebGoat Docker startOfficial image, loopback-only ports
docker version

docker pull webgoat/webgoat:v2025.3

docker run --name webgoat -d   -p 127.0.0.1:8080:8080   -p 127.0.0.1:9090:9090   -e TZ=Etc/UTC   webgoat/webgoat:v2025.3

docker logs -f webgoat

Replace Etc/UTC with a suitable IANA timezone such as Asia/Jerusalem, Europe/Berlin, or America/Toronto. When the log shows that the application has started, press Ctrl+C to stop following the log; the container continues running.

2. Register locally

Create a unique disposable username and password. There is no universal default account.

3. Use WebWolf when asked

127.0.0.1:9090/WebWolf/

4. Stop after the lesson

Run docker stop webgoat, or remove it with docker rm -f webgoat.

OWASP WebGoat Docker installation with localhost-only WebGoat and WebWolf ports

What Is OWASP WebGoat?

WebGoat is a deliberately insecure application maintained by OWASP to teach common server-side application weaknesses. It is implemented with Java and Spring Boot and organizes training into guided lessons that normally explain a concept, present an assignment, offer hints, and conclude with mitigation guidance.

The project is useful for developers studying secure coding, students learning application security, instructors building repeatable classes, testers practicing browser-proxy workflows, and defenders learning what vulnerable application behavior looks like. It is not a public target and should not be treated as a complete benchmark for every modern application or API security requirement.

Guided lessons

Lessons connect vulnerable behavior to root cause and mitigation rather than presenting only an unstructured challenge.

Java application

The maintained project is a Java and Spring Boot application. WebGoat.NET is a separate legacy project.

WebWolf companion

Selected lessons use WebWolf as an attacker-controlled mailbox, file host, or request receiver inside the lab.

Disposable environment

Use synthetic data, a local account, a known image tag, and a clear shutdown or reset process.

Safety Boundaries Before Running WebGoat

The project's own documentation warns that the application makes the host intentionally vulnerable while it is running. The default loopback configuration reduces exposure, but containerization does not turn a deliberately insecure service into a production-safe application.

BoundaryWhy it mattersRecommended practice
Network exposureWebGoat intentionally contains exploitable behaviorKeep both published ports on 127.0.0.1
AuthorizationTraining does not permit testing unrelated systemsUse only your own or explicitly authorized lab
CredentialsLesson data may be stored or displayedRegister a disposable account and password
DataInputs may appear in responses, logs, or lesson stateUse synthetic values only
LifecycleAn existing container can retain local lesson progressStop it after use and remove it for a clean reset
Internet accessA vulnerable lab should not be exposed to untrusted trafficPrefer an isolated workstation or disposable VM
Do not replace 127.0.0.1 with 0.0.0.0 merely to make the lab easier to reach. A supervised class that needs shared access should use an isolated private network, temporary infrastructure, explicit firewall controls, and a shutdown plan.

Install WebGoat on Ubuntu, RHEL and Windows

The WebGoat runtime command is almost identical across platforms. The main difference is how Docker is installed and whether the Docker command needs administrative privileges.

Ubuntu installation

Use Docker's official APT repository. Docker currently documents Ubuntu 22.04, 24.04, 25.10, and 26.04 among its supported 64-bit releases. Review conflicting packages and firewall implications before installing Docker on an existing managed system.

Ubuntu: install Docker and run WebGoatOfficial repository and loopback-only ports
sudo apt update
sudo apt install -y ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg   -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc

sudo tee /etc/apt/sources.list.d/docker.sources > /dev/null <<EOF
Types: deb
URIs: https://download.docker.com/linux/ubuntu
Suites: $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}")
Components: stable
Architectures: $(dpkg --print-architecture)
Signed-By: /etc/apt/keyrings/docker.asc
EOF

sudo apt update
sudo apt install -y docker-ce docker-ce-cli containerd.io   docker-buildx-plugin docker-compose-plugin
sudo systemctl enable --now docker
sudo docker run --rm hello-world

sudo docker run --name webgoat -d   -p 127.0.0.1:8080:8080   -p 127.0.0.1:9090:9090   -e TZ=Etc/UTC   webgoat/webgoat:v2025.3

sudo docker logs -f webgoat

Official reference: Docker Engine on Ubuntu. Using sudo docker avoids silently granting the current account powerful Docker-daemon access.

Red Hat Enterprise Linux installation

Docker currently documents maintained RHEL 8, 9, and 10 releases. Remove or review conflicting container packages before installing Docker Engine from Docker's RPM repository.

RHEL: install Docker and run WebGoatSupported RHEL releases and local-only access
sudo dnf -y install dnf-plugins-core
sudo dnf config-manager --add-repo   https://download.docker.com/linux/rhel/docker-ce.repo
sudo dnf install -y docker-ce docker-ce-cli containerd.io   docker-buildx-plugin docker-compose-plugin
sudo systemctl enable --now docker
sudo docker run --rm hello-world

sudo docker run --name webgoat -d   -p 127.0.0.1:8080:8080   -p 127.0.0.1:9090:9090   -e TZ=Etc/UTC   webgoat/webgoat:v2025.3

sudo docker logs -f webgoat

Official reference: Docker Engine on RHEL.

Windows installation with Docker Desktop

Install Docker Desktop, normally using its WSL 2 backend, start it in Linux-container mode, and verify that the Docker client can reach the engine. Docker Desktop licensing requirements may apply to larger commercial organizations.

Windows PowerShell: run WebGoatDocker Desktop with Linux containers
wsl --version
wsl --update

docker version
docker pull webgoat/webgoat:v2025.3

docker run --name webgoat -d `
  -p 127.0.0.1:8080:8080 `
  -p 127.0.0.1:9090:9090 `
  -e TZ=Etc/UTC `
  webgoat/webgoat:v2025.3

docker logs -f webgoat

Official reference: Docker Desktop on Windows.

Cross-platform OWASP WebGoat installation on Ubuntu RHEL and Windows with the official Docker image

WebGoat Registration, Login and WebWolf

Current WebGoat normally opens a login and registration experience. A new learner should create a local account rather than searching for a universal default username and password.

WebGoat home

http://127.0.0.1:8080/WebGoat/

Registration

Create disposable credentials that are not used anywhere else.

WebWolf

http://127.0.0.1:9090/WebWolf/

Context path

Keep the capitalized /WebGoat/ and /WebWolf/ paths.

WebWolf supports selected assignments that need a second lab-controlled service. It may receive requests, hold a temporary file, or simulate an external mailbox or attacker-controlled endpoint. Use the account and workflow presented by your installed lesson rather than copying credentials or exact answers from a different release.

Progress behavior: stopping and restarting the same container normally retains its writable container state. Removing the container creates a clean environment the next time it is launched. Record anything important in sanitized notes rather than relying on a disposable container as permanent storage.

Choose Docker, the Desktop Image, a Standalone JAR or Source

OptionBest forRequirementsBuyer or learner note
Official Docker imageMost learners and repeatable classesDockerRecommended default
WebGoat desktop imageSelf-contained browser workstationDocker and more resourcesUseful for workshops
Versioned release JARStandalone Java demonstrationsCompatible Java runtimeCheck the release asset and requirements
Current sourceContributors and source-level debuggingGit, Java 25, Maven wrapperMain may differ from v2025.3
WebGoat.NETLegacy .NET-specific studyLegacy project stackSeparate project

Browser-based desktop image

The official README provides a separate image that runs a complete Linux desktop in the browser. It can be useful when a workshop wants the training tools and WebGoat environment bundled together.

WebGoat desktop imageOpen http://127.0.0.1:3000
docker run --name webgoat-desktop -d   -p 127.0.0.1:3000:3000   webgoat/webgoat-desktop

docker logs -f webgoat-desktop

Standalone release JAR

Download a versioned asset only from the official Releases page. Do not assume that an old tutorial's JAR filename or Java requirement applies to the latest release. Confirm the downloaded filename and the release notes, then run it locally.

Standalone JAR patternReplace the placeholder with the actual release asset
java -version

# Replace the placeholder with the downloaded official asset
java -Dfile.encoding=UTF-8 -jar <webgoat-release.jar>

# Optional alternate ports
java -Dfile.encoding=UTF-8 -jar <webgoat-release.jar>   --webgoat.port=8001   --webwolf.port=8002

Build current source

The current main-branch README lists Java 25 as a source-build prerequisite. Use the Maven wrapper included in the repository and record the commit because the main branch can move ahead of the latest release.

Linux or macOS: current sourceJava 25 and Git required
git clone https://github.com/WebGoat/WebGoat.git
cd WebGoat
git rev-parse HEAD
java -version

./mvnw clean install
./mvnw spring-boot:run

Use an Intercepting Proxy Without Publishing the Lab

The official project recommends custom local hostnames when using ZAP, Burp Suite, or another browser proxy. This lets the proxy distinguish WebGoat and WebWolf while both names still resolve to the loopback address.

  1. Add 127.0.0.1 www.webgoat.local www.webwolf.local to the local hosts file.
  2. On Linux, edit /etc/hosts. On Windows, edit C:\Windows\System32\drivers\etc\hosts with administrative permission.
  3. Start the container with the two host environment variables.
  4. Configure the browser to use the local proxy and visit the custom local names.
Proxy-friendly local hostnamesNames still resolve to 127.0.0.1
docker rm -f webgoat 2>/dev/null || true

docker run --name webgoat -d   -p 127.0.0.1:8080:8080   -p 127.0.0.1:9090:9090   -e WEBGOAT_HOST=www.webgoat.local   -e WEBWOLF_HOST=www.webwolf.local   -e TZ=Etc/UTC   webgoat/webgoat:v2025.3

Open http://www.webgoat.local:8080/WebGoat/ and http://www.webwolf.local:9090/WebWolf/. Do not map the service to a general network interface simply because a proxy is involved.

Make WebGoat Workshops Repeatable

Lesson wording, assignments, images, and dependencies can change between releases. A reliable class records the image tag, digest, host timezone, Docker version, date verified, and any known lesson issues.

Record the image tag and digestUseful for workshops and troubleshooting
docker pull webgoat/webgoat:v2025.3
docker image inspect webgoat/webgoat:v2025.3   --format '{json .RepoDigests}'

docker version
docker inspect webgoat --format '{.Config.Image}'
docker logs webgoat 2>&1 | head -n 80
PracticeEvidenceWhy it helps
Pin the tagwebgoat/webgoat:v2025.3Prevents surprise lesson changes
Record the digestOutput from docker image inspectIdentifies the exact image content
Set the timezoneIANA TZ valueReduces JWT and time-based lesson failures
Use disposable accountsClass-specific naming conventionAvoids credential reuse
Document reset stepsStop, remove, and recreate commandsRestores a known starting state

WebGoat Troubleshooting: Startup, Ports and Login

Most failures come from Docker not running, an exited container, a port conflict, the wrong context path, a timezone mismatch, or instructions written for another release.

Inspect the container before reinstallingStatus, logs, ports, and image identity
docker ps -a --filter name=webgoat
docker logs --tail 200 webgoat
docker inspect webgoat --format '{.Config.Image}'

# Linux port check
sudo ss -lntp | grep -E ':8080|:9090' || true

# Recreate on alternate host ports when necessary
docker rm -f webgoat 2>/dev/null || true
docker run --name webgoat -d   -p 127.0.0.1:8081:8080   -p 127.0.0.1:9091:9090   -e TZ=Etc/UTC   webgoat/webgoat:v2025.3
SymptomLikely causeFix
docker: command not foundDocker is missing or not in PATHUse the official platform installation section
Browser cannot connectDocker Desktop is stopped, the container exited, or startup is incompleteRun docker ps -a and inspect logs
Port already allocatedAnother process uses 8080 or 9090Map host ports 8081 and 9091
404 or wrong pageThe context path was omitted or incorrectly capitalizedOpen /WebGoat/
Registration or login behaves unexpectedlyStale browser state or release mismatchUse a private window and verify the installed image
JWT lesson fails unexpectedlyHost and container timezone differRecreate the container with the correct TZ
Walkthrough does not matchThe walkthrough targets another WebGoat releaseUse built-in hints and matching release notes

Use WebGoat as a Defensive Learning Environment

A useful walkthrough teaches a repeatable method, not only an answer. Exact lesson fields can change, but the reasoning remains valuable across releases.

  1. Read the lesson objective. Describe the weakness or control in one sentence.
  2. Create a normal baseline. Record the normal request, response, visible result, and timing.
  3. Change one controlled variable. Keep the result interpretable and remain within the lesson.
  4. Compare allowed and denied behavior. One surprising response is not enough evidence.
  5. Use the built-in hints. They are more likely to match the installed version than an old answer page.
  6. Explain the root cause. Identify the missing validation, authorization, parameterization, or design control.
  7. Write the mitigation. Describe the secure implementation and a regression test.
  8. Capture minimal evidence. Avoid placing passwords, session tokens, or sensitive values in notes and logs.

WebGoat's lesson catalog can support study of injection, access control, authentication, cryptography, request handling, and other application-security topics. The current released awareness list is the OWASP Top 10:2025, but WebGoat should not be presented as a one-to-one implementation of every current category or as a complete verification standard.

The transferable skill is not memorizing a lab answer. It is being able to explain the trust boundary, reproduce the behavior safely, identify the missing control, and verify the mitigation.
Defensive OWASP WebGoat learning workflow from controlled observation to mitigation and regression testing

WebGoat Installation and Safety Checklist

CheckExpected evidenceStatus
Official sourceOWASP project, WebGoat/WebGoat, or webgoat Docker Hub accountRequired
Pinned releasev2025.3 tag and recorded digest for repeatable trainingRecommended
Loopback bindingBoth host mappings begin with 127.0.0.1Required
TimezoneContainer TZ matches the hostRequired for selected lessons
Disposable accountNo reused personal or corporate passwordRequired
Correct URLs/WebGoat/ and /WebWolf/Required
Safe evidenceSanitized notes without raw credentials or tokensRequired
ShutdownContainer stopped or removed after the lessonRequired

Primary Sources Used for This Guide

OWASP WebGoat Installation and Login FAQs

What is OWASP WebGoat?

OWASP WebGoat is a deliberately insecure Java and Spring Boot application maintained by OWASP for authorized application-security education. Its guided lessons explain vulnerabilities, provide controlled assignments, and describe mitigations. Run it only on localhost or in an isolated lab you own or are explicitly authorized to use.

What is the fastest safe way to install WebGoat?

Install Docker, then run the official webgoat/webgoat image with ports 8080 and 9090 bound to 127.0.0.1. Set the TZ environment variable to your IANA timezone, wait for the startup log, and open http://127.0.0.1:8080/WebGoat/.

What is the official WebGoat Docker command?

The official project publishes ports 8080 and 9090 on loopback. A repeatable example is docker run --name webgoat -d -p 127.0.0.1:8080:8080 -p 127.0.0.1:9090:9090 -e TZ=Etc/UTC webgoat/webgoat:v2025.3. Replace Etc/UTC with the correct IANA timezone.

What URL opens WebGoat?

Open http://localhost:8080/WebGoat/ or http://127.0.0.1:8080/WebGoat/. The context path uses a capital W and G. Opening only the server root can be less reliable than using the complete /WebGoat/ path.

Does WebGoat have a default username and password?

Current WebGoat normally asks each learner to register a local account. There is no universal default login to rely on. Create disposable credentials used only for this local lab and never reuse a real password.

What is WebWolf and where do I open it?

WebWolf is WebGoat's companion application for lessons that need an attacker-controlled mailbox, file host, request receiver, or related lab service. With the standard Docker ports, open http://127.0.0.1:9090/WebWolf/.

What is the current WebGoat release?

As of August 5, 2026, GitHub marks v2025.3, released March 11, 2025, as the latest WebGoat release. Docker Hub also publishes a v2025.3 image for amd64 and arm64. Recheck the official Releases page before reusing saved workshop instructions.

How do I install WebGoat on Ubuntu?

Install Docker Engine from Docker's official Ubuntu repository, verify the engine with hello-world, and run the official WebGoat image with both ports bound to 127.0.0.1. Then open localhost:8080/WebGoat from the same computer.

How do I install WebGoat on RHEL?

Use Docker's official RHEL repository on a supported RHEL 8, 9, or 10 system, start Docker, verify it with hello-world, and run the official WebGoat image with loopback-only port bindings.

How do I install WebGoat on Windows?

Install and start Docker Desktop in Linux-container mode, normally with the WSL 2 backend. Run the PowerShell Docker command in this guide, wait for WebGoat to initialize, and open localhost:8080/WebGoat.

Why is localhost:8080/WebGoat not loading?

Confirm Docker is running, inspect docker ps -a, and review docker logs webgoat. Check whether ports 8080 or 9090 are already in use, confirm the capitalized /WebGoat/ path, and allow time for the Spring Boot application to start.

How do I stop, reset, or remove WebGoat?

Run docker stop webgoat to stop it while keeping the container. Run docker start webgoat to resume it. Run docker rm -f webgoat to remove the container and its local progress. Recreate it from the same pinned image when you need a clean lab.

Turn lab lessons into repeatable security controls

WebGoat helps teams observe individual application weaknesses in a controlled environment. Real programs also need secure design requirements, automated verification, inventory, production evidence, incident response, and controlled protection across applications and APIs.

WebGoat, Docker, release, and OWASP guidance reviewed August 5, 2026. Use the lab only on systems you own or are authorized to test, keep it on loopback or an isolated network, and verify official sources before reusing saved commands.