The short answer: an ExtentReports HTML file usually contains a reference to a screenshot file, not the image itself. Copying only the HTML therefore produces empty thumbnails or broken images on another computer. Package the report, its media directory, and the exact relative folder structure together—or use Base64 embedding when your reporter and adapter support it.
Start by inspecting the generated image reference and identifying your ExtentReports version, reporter, language binding, and test adapter. The correct setting depends on that combination.
Why the report works locally but not elsewhere
File-based ExtentReports screenshot methods save an image on disk and place an <img> reference in the report. The HTML does not automatically carry that separate file. ExtentReports documentation describes this behavior explicitly: the screenshot is saved to disk and referenced by the report’s image tag.
On your development machine, the referenced path exists. After emailing only the HTML, copying it to a different workstation, or publishing an incomplete CI artifact, the browser cannot resolve that path. The result may be a blank thumbnail, a broken-image icon, or a report that loads with no visible screenshot.
Free tools Windows power users keep installed
One-click scans. No signup required.
#1 Best Overall
- CRISP CLARITY: This 23.8″ Philips V line monitor delivers crisp Full HD 1920x1080 visuals. Enjoy movies, shows and videos with remarkable detail
- INCREDIBLE CONTRAST: The VA panel produces brighter whites and deeper blacks. You get true-to-life images and more gradients with 16.7 million colors
- THE PERFECT VIEW: The 178/178 degree extra wide viewing angle prevents the shifting of colors when viewed from an offset angle, so you always get consistent colors
- WORK SEAMLESSLY: This sleek monitor is virtually bezel-free on three sides, so the screen looks even bigger for the viewer. This minimalistic design also allows for seamless multi-monitor setups that enhance your workflow and boost productivity
- A BETTER READING EXPERIENCE: For busy office workers, EasyRead mode provides a more paper-like experience for when viewing lengthy documents
There are two delivery models:
| Model | What is delivered | Portability | Trade-off |
|---|---|---|---|
| External image files | HTML plus PNG/JPEG/WebP files in a referenced directory | Portable when the directory tree and relative paths are preserved | Small report, but every referenced file must be packaged |
| Base64 embedding | Image data stored inside the HTML | No separate screenshot path to break | Much larger HTML and possible memory pressure with many images |
Neither model is universally best. External files suit large suites and CI artifacts; embedding can be convenient for a small report that must be a single file.
Diagnose the exact broken path first
- Record the stack. Write down the ExtentReports version, reporter (Spark, Logger, or an adapter-managed reporter), Java or other language binding, and adapter version (for example, Cucumber-JVM).
- Open the HTML source. In the report directory, open the generated HTML in a text editor and search for
<img,src=, or a distinctive screenshot filename. - Classify the
src. An absolute drive path such asC:agentworkscreenshotsfail.pngis tied to the original machine. A relative path such as../screenshots/fail.pngis portable only if it is calculated from the report’s location and the target file exists. - Resolve from the report directory. Do not resolve a relative URL from the test process’s working directory. Starting at the HTML file’s directory, follow the
srcsegments and verify that the image is present there. - Inspect the bundle. Open the ZIP, CI artifact, or shared folder on the destination machine. Confirm that the image directory and its contents were included, not merely the top-level HTML file.
- Reopen after moving it. Test the report from the final destination, because a path that worked inside a build workspace may fail once the bundle is nested under a different folder.
This sequence separates three different failures: a path generated incorrectly, a valid path pointing to an untransferred file, and a file that was copied but later moved relative to the report.
Fix external screenshots by preserving the directory tree
Use a portable package
Put the report and media under one predictable root, for example:
artifact/
artifact/report/index.html
artifact/report/media/fail-001.png
artifact/report/media/pass-002.png
If the HTML contains media/fail-001.png, moving the entire artifact directory preserves the relationship. Do not rename or flatten media during upload. In CI, publish the whole report root as one artifact rather than selecting only index.html.
Recommended Free Tools
Eliminate absolute path construction
Build screenshot paths from the report and media directories instead of concatenating a machine-specific workspace path. Avoid code that splits a path on a literal directory name such as reports and then prepends ../. That approach only works for one naming and nesting convention; a different checkout path or report folder produces a wrong reference.
Rank #2
- CRISP CLARITY: This 22 inch class (21.5″ viewable) Philips V line monitor delivers crisp Full HD 1920x1080 visuals. Enjoy movies, shows and videos with remarkable detail
- 100HZ FAST REFRESH RATE: 100Hz brings your favorite movies and video games to life. Stream, binge, and play effortlessly
- SMOOTH ACTION WITH ADAPTIVE-SYNC: Adaptive-Sync technology ensures fluid action sequences and rapid response time. Every frame will be rendered smoothly with crystal clarity and without stutter
- INCREDIBLE CONTRAST: The VA panel produces brighter whites and deeper blacks. You get true-to-life images and more gradients with 16.7 million colors
- THE PERFECT VIEW: The 178/178 degree extra wide viewing angle prevents the shifting of colors when viewed from an offset angle, so you always get consistent colors
Prefer the path APIs supplied by your language (for example, Java’s Path.resolve and relativize) and log the final path during a failing test. The generated HTML is the authority: verify what was written, not what a configuration variable was intended to produce.
Cucumber-JVM 7 adapter: align both screenshot settings
The Cucumber-JVM 7 adapter README defines two related properties:
screenshot.dir: the directory in which attachments are stored.screenshot.rel.path: the relative path from the report file to that screenshot directory.
They must describe the actual output tree. The documented example uses screenshot.dir=test-output/ and screenshot.rel.path=../ when the report is nested at test-output/SparkReport/. Those values are an example, not universal defaults.
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →Clear out junk files and repair common Windows errorsFree Scan →For a different layout, calculate the relationship explicitly. If your report is at build/reports/extent/index.html and images are at build/reports/extent/screenshots/, the relative path from the report to the directory is screenshots/. If images are at build/screenshots/, the relative path is ../screenshots/. After changing either property, generate a report and inspect one real src value.
LoggerReporter’s automatic relative-media option
For ExtentReports v4 LoggerReporter, the documented setting is:
Rank #3
- Clear visuals. Fluid motion: A 144Hz refresh rate and 1ms MPRT deliver smooth, tear‑free motion across work, gaming, and streaming for clearer, more fluid viewing.
- Eye comfort: TÜV Rheinland 3‑star* certification reduces harmful blue light while preserving stunning color quality without compromise. *TÜV Rheinland 3-star eye comfort certification.
- Wide viewing angle: Get consistent views across a wide 178° /178° viewing angle.
- In-Plane Switching (IPS): See excellent color accuracy and consistency across wide viewing angles with In-plane Switching (IPS) technology.
- Ultra-thin bezels: Maximize your viewing experience with thin bezels.
logger.config().setAutoCreateRelativePathMedia(true);
It makes the reporter copy media to a directory relative to the report and reference that location, so the report and generated media directory can be moved together. LoggerReporter documentation also notes that it creates incremented extent-media directories and does not automatically remove them; include the directory that belongs to the report you are sharing and clean old output deliberately.
This advice is LoggerReporter-specific. The same documentation says LoggerReporter has been deprecated since version 4.1.3 and replaced by ExtentSparkReporter. Do not assume this method exists on SparkReporter or in an adapter-managed configuration. Check the exact API and version you use before adding it.
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Use Base64 when a single self-contained file is worth the cost
ExtentReports v4 core documents Base64 methods for both tests and log entries:
test.addScreenCaptureFromBase64String(base64Image);
MediaEntity media = MediaEntityBuilder
.createScreenCaptureFromBase64String(base64Image)
.build();
test.fail("Failure", media);
The exact overload and attachment flow depend on your binding and reporter. The Cucumber-JVM 7 adapter also documents a Spark Base64-image option. Verify that your precise adapter version supports it before changing configuration.
When embedding is a good fit
- A small number of screenshots must travel as one HTML file.
- Recipients will open the file outside the build workspace.
- Your publishing system cannot preserve a directory tree.
When to keep files external
- The suite generates hundreds or thousands of images.
- Images are large or full-page.
- You need a lightweight HTML report and independently downloadable evidence.
Embedding can inflate the report substantially, and the adapter documentation warns that many Base64 images may cause memory issues. For large suites, package the external media directory instead.
Rank #4
- CURVED FOR ENHANCED ENGAGEMENT: An immersive viewing experience with a curved monitor that wraps more closely around your field of vision; It creates a wider view, enhancing depth perception and minimizing peripheral distraction
- SMOOTH PERFORMANCE FOR SEAMLESS CONTENT: Stay in the action when playing games, watching videos, or working on creative projects; The 100Hz refresh rate reduces lag and motion blur so you don't miss a thing in fast-paced moments¹
- MORE GAMING POWER: Gain the edge with optimizable game settings; Color and image contrast can be adjusted to see scenes more vividly and spot enemies hiding in the dark; Game Mode adjusts any game to fill the screen so you can view every detail²
- KEEP IT EASY ON THE EYES: Care for your eyes and stay comfortable, even during long sessions; Advanced eye comfort technology certified by TÜV reduces eye strain by minimizing blue light and reducing irritating screen flicker²
- INCREASED VERSATILITY: Connect to more; Plug devices straight into your monitor for increased flexibility, making your computing environment even more convenient
CI and sharing checklist
- Generate the report and screenshots into a known output root.
- Ensure the report is finalized before the CI job uploads artifacts.
- Publish the report directory and every referenced media directory together.
- Preserve case-sensitive filenames; Linux runners and some artifact stores distinguish
Fail.pngfromfail.png. - Do not open the report through a different URL prefix that changes relative resolution unless the files remain underneath the same report directory.
- Download the artifact, extract it into a clean temporary directory, and open the report there before sending the link.
- Retain the generated folder structure when attaching a ZIP to a ticket or email.
Common symptoms and targeted fixes
| Symptom | Likely cause | Fix |
|---|---|---|
| Broken image icon and an absolute local path in source | Machine-specific path was written | Generate a report-relative path or use supported Base64 embedding |
Relative src, but no image in the ZIP |
Artifact contains HTML only | Upload the screenshot directory and preserve its location |
| Images exist, but every thumbnail is blank | Relative path is calculated from the wrong directory or has incorrect ../ depth |
Resolve the URL from the HTML file’s directory and correct adapter settings |
| Works in one report folder but not after moving it | Report and media were separated or flattened | Move the complete report root as a unit |
| Only old runs show images | Incremented media directories were not included or were cleaned | Match the report to its generated media directory and retain both |
| Report becomes extremely large or generation runs out of memory | Too many Base64 images | Use external files, reduce image volume, or embed only a small subset |
| Logger setting has no effect | Reporter is Spark or adapter-managed, not LoggerReporter | Confirm the reporter and consult its version-specific configuration |
Performance, reliability, and cost considerations
External images generally keep HTML parsing and transfer lighter, but reliability depends on complete artifact publication and stable relative paths. Base64 removes file-server and path failures, but increases HTML size, memory consumption, and upload time as image count grows. Full-page screenshots and high-resolution images amplify both costs.
Do these 3 things before closing this tab:
1Clear out junk files and repair common Windows errors2Fix the driver behind crashes, sound loss and screen glitches3Repair Windows errors before they cause bigger problemsFor repeatable CI runs, use a unique output directory per run, finalize the report once, and archive the complete directory. If you must expose reports over a web server, keep media beneath the report URL and avoid rewriting only the HTML file into a different location.
Or skip the browser setup
If your goal is simply to obtain portable website screenshots rather than attach Selenium evidence to ExtentReports, ScreenshotNeo provides a one-request API. It accepts the cookie or consent banner before capture and removes more than 60 known consent platforms, newsletter popups, and chat widgets; each step can be disabled. Bot checks, CAPTCHAs, blank pages, timeouts, failed loads, and cache hits are not billed, and the response reports the result through X-Page-Verdict and X-Billed headers. Its MCP server also lets Claude, Cursor, or another MCP client call take_screenshot, get_page_info, and capture_pdf.
See the ScreenshotNeo API documentation for authentication and options. A cURL request is:
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
Python:
import requests
r = requests.get("https://api.screenshotneo.com/v1/shot", params={"access_key": "YOUR_API_KEY", "url": "https://stripe.com"}, timeout=90)
open("shot.webp", "wb").write(r.content)
Node.js:
const q = new URLSearchParams({ access_key: 'YOUR_API_KEY', url: 'https://stripe.com' });
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);
ScreenshotNeo supports full-page captures with lazy images loaded, CSS-selector element capture, dark mode, device presets or custom viewports, retina scale, PDF output, custom CSS and JavaScript, clicks, selector or network-idle waits, request blocking, headers, cookies, user agents, authorization, timezone, geolocation, transparent backgrounds, resizing, TTL caching, signed links, asynchronous webhooks, bulk capture of up to 100 URLs per call, a usage API, and an OpenAPI specification. Parameter names used by other screenshot APIs also work.
The Free plan includes 1,000 screenshots per month with no card. Paid plans start at $5 for 3,000 screenshots; yearly billing gives two months free, and every feature is available on every plan. Create a free ScreenshotNeo account.
Best Value
- 【INTEGRATED SPEAKERS】Whether you're at work or in the midst of an intense gaming session, our built-in speakers provide rich and seamless audio, all while keeping your desk clutter-free.
- 【EASY ON THE EYES】 Protect your eyes and enhance your comfort with Blue-Light Shift technology. This feature reduces harmful blue light emissions from your screen, helping to alleviate eye strain during long hours of use and promoting healthier viewing habits.
- 【WIDEN YOUR PERSPECTIVE】Our sleek minimal bezel design ensures undivided attention. The nearly bezel-free display seamlessly connects in a dual monitor arrangement, delivering an unobstructed view that lets you focus on more at once, completely distraction-free.
Frequently Asked Questions
Should I send only the ExtentReports HTML file?
No. If the report uses file-based screenshots, send the HTML and every referenced image while preserving the relative directory structure.
Is Base64 always supported by SparkReporter?
Support depends on the exact ExtentReports binding, reporter, adapter, and version. Verify the API available in your setup before enabling it.
Where is a relative screenshot path resolved from?
From the directory containing the generated HTML report, not from the test process’s current working directory.
Why did a LoggerReporter fix fail after switching to Spark?
The automatic relative-media setting is documented for LoggerReporter, which has been deprecated since ExtentReports 4.1.3. SparkReporter requires its own version-specific configuration.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




