"It works great and it is stunningly fast - on production, converting 115.000 documents takes 25 seconds instead of 9 hours." — Robert S., Germany

ScroogeXHTML RTF converter

Fast and compact RTF to HTML5 converter library for the Java SE platform

Live RTF to HTML5 conversions

Created "on-the-fly" from locally stored documents. Experimental features are enabled.
Version 10.5.0.

Code Example

code

Java code

ScroogeXHTML scrooge = new ScroogeXHTML();
scrooge.setAddOuterHTML(true);
String html = scrooge.convert("{\\rtf1 \"Hello world!\"}"); 
System.out.println(html);

HTML output

<!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8">
    <title>Untitled document</title>
    <meta content="ScroogeXHTML RTF converter 10.5.0" name="generator">
  </head>
  <body>
    <p>"Hello world!"</p>
  </body>
</html>

ScroogeXHTML is a library which supports a subset of the Rich Text Format (RTF) standard. It converts RTF to HTML5 and XHTML standalone documents, or to fragments which can be embedded in other documents.

link

Supports hyperlinks, bookmarks, multi-language and LTR/RTL text, field results and simple tables

format_size

Minimizes documents using CSS font definitions and generation of local font styles for text with different attributes

find_replace

Includes an API for post-processing of the intermediate DOM tree to support additional fine tuning

settings

Easy to use, compact and fast, and requires no external runtime libraries except the SLF4J logging facade

language

The web-based online demo converts your RTF document to HTML5 and allows to configure the conversion

Open online demo
portrait

Picture data extraction, complimentary code for embedding BMP/JPG/PNG images as Data URIs

Text properties
Bold/italic/underlined ✓/✓/✓
Foreground/background/highlight color ✓/✓/✓
Subscript/superscript ✓/✓
Strikethrough/hidden ✓/✓
LTR/RTL text ✓/✓
Unicode/DBCS text ✓/✓
Language attribute
Paragraph properties
Left/right/centered/justified alignment ✓/✓/✓/✓
Left/right/first line indent ✓/✓/✓
Background color
Border box color/width ✓/✓
Space before/after ✓/✓
Numbered/unnumbered lists ✓/✓
Tabulators replaced by a sequence of non breaking spaces
Other content
External Hyperlinks
Internal Links (Bookmarks)
Pictures
Picture data extraction
Extracted picture formats BMP/EMF/JPG/PICT/PNG/WMF
Supported picture storage types Binary / Hexadecimal
Picture data conversion
• BMP to PNG conversion (using ImageIO)
• PICT to PNG conversion (using ImageIO, new in 10.1)
• WMF to PNG conversion (requires external converter)
Picture embedding Data URI
Tables
Simple tables / Nested tables ✓/
Total width: pixel/percent ✓/✓
Left margin: pixel/percent ✓/✓
Column width: pixel/percent ✓/✓
Row height
Horizontal cell merging
Cell background color
Cell border color/width /✓
Output document types
HTML5
XHTML 1.0 Transitional
Optimization
CSS based document minimizer
Font name substitution
Advanced features
Header/Footer text
Post processing events
Footnotes
Platforms
Java SE 8 platform Tested ✓
Java SE 11 platform Tested ✓
Java SE 17 platform Tested ✓
Java SE 21 platform Tested ✓

① Uses direct text formatting, does not generate HTML ol or ul elements.

② Limited support, complimentary and/or experimental feature.

③ The complimentary class MemoryPictureAdapterDataURI supports embedding pictures as Data URIs.

Prices are per developer seat.

Released 4 February 2024

book

Manual

The "Getting Started" user guide

search

API Docs

Online API documentation

list

Release Notes

Enhancements and bug fixes

help_outline

FAQ

Frequently Asked Questions

alternate_email

Contact

Support and sales inqueries

pages

Blog

Technical articles and announcements

Released 4 February 2024

get_app

Installer — Source Edition:

Download »

get_app

Installer — Jar Edition:

Download »

General

get_app

On the library home page you will find a link to the download area for registered users. The credentials (user name and password) will be sent to you when a new release is available. New releases will also be announced on the blog.

Go to the download section

check

Yes, a free online demo version is available at https://www.scroogexhtml.com/sxd. There is also a time-limited trial version of the Jar edition.

Go to the online demo

Picture Support

help_outline

The library does not convert embedded pictures, it only extracts the raw picture data from the RTF document. The library may contain complimentary code for picture processing support, but this code is experimental and not covered by the basic support plan.

Privacy and Security

Upgrading

check

Yes, you may receive a discount coupon code to purchase the Source Edition at a reduced price.

Developer License

check

Yes, each developer that uses our products must have their own license.

No, developer licenses are perpetual. However, you will be using the last product version released before your free upgrade period expired. A license may also be revoked in case of license violations.

Source Code Distribution

block

No, the source code is not redistributable, even if you change it. Under no circumstances is it acceptable to disclose the source to any third party.

Server Deployment License

help_outline

License types (Single Developer License and Server Deployment License) are explained on the page /scroogexhtml_license.html.

ScroogeXHTML License Types

No. A Server Deployment License covers all applications on the server.

help_outline

Server Deployment Licenses are available under two license models, 'Perpetual' or 'Subscription'. When licensed as a subscription, the license expires when the subscription ends. Licenses may also expire in case of license violations.

No, the proof of purchase for Server Deployment Licenses is your license document.

block

No. ScroogeXHTML Server Deployment Licenses or parts of it may not be distributed, sold, rented or transferred to any other party, this includes mergers and acquisitions of the license holder.

Acesis

Actiance

Advocate Health Care

Artisan Design Group

Axalta Coating Systems

Becton, Dickinson and Company

Bracari

General Dynamics

Glencore International AG

iBASEt

Iodine Software

PAGU.at

ProClarity Corporation

QuadraMed Corporation

Working Systems Cooperative

format_quote

"This is an excellent unique product that has saved us many hours of work. It is simple to use with lots of documentation." — Stewart S., UK

format_quote

"It works great and it is stunningly fast - on production, converting 115.000 documents takes 25 seconds instead of 9 hours." — Robert S., Germany