Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Highcharts’ PhantomJS export path is deprecated and no longer maintained, so treat a broken export as both a troubleshooting problem and a migration warning. For a legacy system, first verify that the input format and chart constructor match, then check that Highcharts and its modules load, inspect dimensions and injected scripts or styles, and capture page errors and resource failures. For new or actively maintained server-side exports, use the Highcharts Node.js export server, which renders with Puppeteer.

Start with the right diagnosis: PhantomJS is a legacy path

Highcharts’ legacy export documentation marks its PhantomJS methods as deprecated and directs users to the newer export-server approach. That makes PhantomJS worth keeping only when compatibility constraints require it; it is not a good foundation for a new deployment. A blank SVG does not necessarily mean Highcharts produced invalid SVG: the chart may never have been constructed, a required module may not have loaded, or the result may have been clipped by an unexpected viewport.

Work through the checks below in order. Each isolates a different stage: input interpretation, script and module loading, chart layout, and output capture. If you can reproduce the problem with a minimal chart, compare that result against the production configuration before changing several settings at once.

Check the input and chart constructor

The legacy converter can accept chart options/configuration or SVG input, and it supports the Chart and StockChart constructors. Confirm which input you are passing and which constructor the chart actually needs. If the converter interprets a configuration file as SVG, or creates a standard chart where the configuration expects a stock chart, the output can be empty or malformed.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • Verify the input is the intended format: chart configuration or SVG.
  • Use StockChart for a stock-chart configuration and Chart for a regular Highcharts chart.
  • Temporarily remove optional modules and custom callbacks from a failing configuration. If the simplified chart renders, add those pieces back individually to find the incompatibility.

Keep a known-good minimal configuration as a control. If it renders in the same PhantomJS environment while the real chart does not, focus on the real chart’s modules, callbacks, CSS, data, and layout rather than treating the entire export installation as broken.

Verify Highcharts scripts and modules load

The PhantomJS process must be able to locate the Highcharts JavaScript files and every module the chart configuration depends on. The legacy setup relies on files being discoverable from PhantomJS’s working directory or from an explicitly configured location. A module path that works in a developer’s browser may fail when the converter runs with a different working directory or filesystem layout.

Missing core scripts can prevent the chart from being created. Missing add-on modules can instead leave a partially working chart: a series, map, stock feature, or other module-dependent path may be absent even though some SVG appears. Check the exact dependencies used by the failing chart, including modules such as highcharts-more.js, data, map, or stock modules where applicable.

Rank #2
Sale
HTML and CSS: Design and Build Websites
  • HTML CSS Design and Build Web Sites
  • Comes with secure packaging
  • It can be a gift option
  • Run the converter from the same working directory and service account used in deployment.
  • Check that each referenced JavaScript file exists at the path the rendering page uses, and that PhantomJS can read it.
  • Look for failed resource requests and JavaScript exceptions before diagnosing the SVG itself.
  • Compare the loaded script list for a successful chart with the failing one; include module order and URL/path differences.

Do not assume that a page displaying a chart in an interactive browser proves that the export environment has loaded the same assets. The renderer may have different paths, permissions, network access, or timing.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Fix clipping, tiny labels, and misplaced elements

Check output geometry before adjusting individual labels. In the legacy converter, scale changes the PhantomJS zoom factor, while width overrides scale and sets an exact output width. A width or scale that does not match the intended chart dimensions can make labels appear clipped, tiny, or outside the visible area.

  1. Record the intended chart width and height and compare them with the converter’s effective viewport and output dimensions.
  2. Set a deliberate width where an exact output width is required. Remember that setting width takes precedence over scale.
  3. If using scale, change it independently of width and inspect the resulting dimensions instead of compensating with several settings at once.
  4. Check chart margins, label rotation, legends, and long axis labels after the overall geometry is correct.

Text placement also depends on fonts and geometry APIs. A font available on a developer workstation may not be installed in the server environment, changing text widths and therefore label positions. Highcharts notes feature differences among SVG clients, and its server-rendering account describes unreliable getBBox behavior in alternative rendering stacks. If layout changes between environments, compare installed fonts and the rendering engine before adding CSS offsets to individual labels.

Rank #3
Sale
Web Design with HTML, CSS, JavaScript and jQuery Set
  • Brand: Wiley
  • Set of 2 Volumes
  • A handy two-book set that uniquely combines related technologies Highly visual format and accessible language makes these books highly effective learning tools Perfect for beginning web designers and front-end developers

Inspect callbacks, CSS, and injected resources

Callbacks, injected JavaScript, CSS, and other files execute inside the rendering page. An exception can stop chart construction; an unsupported DOM API can behave differently from a modern browser; and a CSS rule can change the chart’s dimensions or visibility without causing an obvious export error.

  • Disable callbacks and custom JavaScript temporarily, then add them back one at a time.
  • Check for syntax errors and browser APIs that PhantomJS may not implement as expected.
  • Remove injected CSS temporarily, especially rules affecting SVG, text, containers, overflow, or display.
  • Confirm that injected files load successfully and that their relative paths resolve from the rendering page.

If the chart becomes correct when a callback, style, or injected file is disabled, reduce that item to the smallest reproducible change. This is safer than layering chart-specific CSS patches onto a failure that originates earlier in page setup.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Capture errors instead of guessing

Run the converter from a shell while preserving both standard output and standard error. Look for failed file loads, page errors, JavaScript exceptions, and any converter-side message about image or SVG generation. The legacy Highcharts troubleshooting instructions also show how to print the Java/Batik command and its output; that is useful when the failure occurs after the PhantomJS stage, while PhantomJS page and resource diagnostics help identify failures inside the rendered page.

When a server response contains little detail, add diagnostic logging around page errors and failed resource requests, and record the input configuration and effective dimensions for each attempt. Keep logs accessible to the operator, but do not expose a diagnostic rendering endpoint publicly. A useful incident record includes:

  • the input type and selected chart constructor;
  • the converter’s working directory and the resolved locations of Highcharts scripts and modules;
  • the requested width, scale, and resulting output dimensions;
  • page exceptions, failed resource URLs, and converter output;
  • whether the same configuration succeeds in the replacement renderer.

This separates a chart configuration problem from a deployment problem and gives you the information needed to decide whether to repair the legacy path or migrate it.

Choose a supported rendering path

The right replacement depends on where rendering happens, whether chart data may leave your network, how much control you need, and whether the chart’s features and fonts behave consistently in the chosen renderer. Highcharts documents both browser-side export and server-side export options. Its export-module overview says client-side exports have been the default since v12.3; PDF generation may require the offline-exporting module and its dependencies.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Option How it renders When it fits Key consideration
Legacy PhantomJS export Uses the deprecated PhantomJS-based path. Temporary compatibility for an existing system that cannot yet migrate. No longer maintained; isolate it and plan a replacement.
Client-side export module Exports in the user’s browser; client-side exports are the default since Highcharts v12.3. Browser-capable applications where the user can initiate the export. Check browser support for the chart features and fonts in use. PDF may require offline-exporting and dependencies.
Highcharts Node.js export server Uses Puppeteer to render chart configuration or SVG to PNG, JPG, PDF, or SVG. Server-side export workloads that need a maintained rendering approach and operational control. Validate the actual chart configuration and assets in the target deployment; Highcharts documents npm installation, command-line conversion, and batch conversion.
Highcharts hosted export service Receives generated SVG and returns an image. When a hosted service is acceptable and keeping the export renderer out of your own deployment is preferable. Consider whether sending the chart’s generated SVG is acceptable for your data and privacy requirements.

The Node.js export server is the direct server-side successor for workloads currently relying on the old converter. Highcharts documents global installation with npm and command-line conversion from a configuration file, as well as batch conversion. Follow the current Highcharts export-server documentation for the installation and command syntax for your environment rather than copying a legacy PhantomJS invocation into a new setup.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Migrate with a compatibility check

Do not treat changing the renderer as a purely mechanical server upgrade. SVG feature support varies among rendering engines, and chart layout can depend on fonts and geometry behavior. Highcharts’ server-rendering article reports one production experience in which PhantomJS became too slow with SVGs containing more than 1,500 data points. That is an attributed experience, not a general performance threshold or benchmark; test your own charts and workload.

  1. Inventory the workload. Identify chart types, modules, custom callbacks, injected styles, fonts, output formats, and the data-sensitivity requirements for each export.
  2. Choose a target. Use client-side export if the application and browser support it and that suits the workflow. Use the Node.js/Puppeteer server for controlled server-side rendering. Consider the hosted service only if sending the generated SVG outside your environment is acceptable.
  3. Run representative charts through both paths. Include charts with long labels, custom fonts, dense data, maps or stock features, and each output format you rely on.
  4. Compare output and operational behavior. Check clipping, text positions, feature availability, output dimensions, and failure logging; measure runtime on your actual workload rather than relying on anecdotes.
  5. Shift traffic gradually. Keep the old renderer private and available only as a controlled fallback until the replacement passes your checks.

Keep a legacy PhantomJS service private

Highcharts explicitly warns that its legacy PhantomJS web server is not intended to be exposed to the outside world or used as a general production server. Bind it to localhost or put it behind a controlled internal service while migrating. Do not publish an unauthenticated endpoint that accepts arbitrary rendering requests. Apart from the security exposure, public access makes it harder to control what gets rendered and how the legacy process is used.

Or skip the browser setup

ScreenshotNeo is a website screenshot API, not a Highcharts SVG export server: it captures a rendered webpage as PNG, JPEG, WebP, or PDF. Use it when your requirement is a screenshot of a page containing a chart, not when you need Highcharts to export chart configuration or SVG directly. One GET request can capture a URL:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

ScreenshotNeo API documentation

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
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)
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 removes cookie banners, newsletter popups, and chat widgets before a shot; bot checks, blank pages, and failed loads are never billed. Its MCP server lets AI agents take screenshots, and the free plan includes 1,000 screenshots a month with no card; paid plans start at $5 for 3,000.

Sign up for ScreenshotNeo’s free plan

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.