|Introduction | Sustainability Factors | Content Categories | Format Descriptions | Contact|
|Full name||RAR Archive File Format Family|
RAR, or the Roshal ARchive format thanks to its namesake creator software developer Eugene Roshal, is a proprietary archive file format that supports data compression, error recovery and file spanning. There are at least six main versions and subversions of the RAR format and because the early versions have little formal documentation, only selected versions currently are described at this site. The early versions RAR1.3 and especially RAR1.5 are thought to be the base for later versions but no public documentation is available about these early versions. Comments welcome. RAR4 is also known as RAR version 2.9 in some documentation. The current version as of this writing is RAR5. See Relationships below for more details.
Similar in purpose to ZIP files, RAR files are data containers in which one or more files are stored in compressed form. RAR is a proprietary format under copyright, along with RAR's compression applications and libraries to Alexander Roshal, brother of Eugene Roshal. RAR files are the native format for WinRAR software and can only be created through this tool which is licensed to win.rar GmbH although there are several options to open RAR files. See External Dependencies for details.
Structurally, a RAR file is comprised of variable length blocks of required and optional data. The precise composition of the blocks evolved over time with the versions. At its core, a RAR file is comprised of a marker or introductory block, an archive block which includes the archive header and file header, and closing block which includes additional comments or other information needed to correctly process the file. The order of these blocks may vary, but the first block must be a marker block followed by an archive header block. The archive block is the most complex because it contains the headers for the archive itself as well as the file headers:
After the main archive header but still within the archive block comes one or more file headers, one for each file within the archive. File headers are followed by optional Service headers.
The End of Archive Marker follows the last File Header to close out the archive block, after which RAR does not read anything to permit third party tools to add extra information such as a digital signature to archive.
|Relationship to other formats|
|Has subtype||RAR1.3, RAR Archive File Format, Version 1.3. No information available. Not described on this site at this time.|
|Has subtype||RAR1.5, RAR Archive File Format, Version 1.5. Often described as the basis for subsequent versions but no detailed information available. Not described at this site at this time.|
|Has subtype||RAR2, RAR Archive File Format, Version 2|
|Has subtype||RAR3, RAR Archive File Format, Version 3|
|Has subtype||RAR4, RAR Archive File Format, Version 4. RAR4 is also known as RAR version 2.9.|
|Has subtype||RAR5, RAR Archive File Format, Version 5|
|LC experience or existing holdings||RAR files have appeared in various personal papers collections as a submission format for large PST email files.|
|Disclosure||Proprietary format with limited public information.|
|Documentation||The full specification is not publicly available but file structure information for RAR5 is available through the RARLab website.|
|Adoption||According to one report, RAR format has gained much popularity over these years as compared to its competitor archive formats like 7Z, zip, etc ... [because it has] better data compression rate than ZIP and uses a lossless compression.|
|Licensing and patents||RAR is a proprietary file format created solely by the compression software WinRAR. The decompression code is available for use in other programs and the license holder allows for its distribution, but with a license provision (detailed in the license.txt file from the UnRAR source code) that "Unrar source may be used in any software to handle RAR archives without limitations free of charge, but cannot be used to re-create the RAR compression algorithm, which is proprietary. Distribution of modified Unrar source in separate form or as a part of other software is permitted, provided that it is clearly stated in the documentation and source comments that the code may not be used to develop a RAR (WinRAR) compatible archiver."|
|Transparency||Transparency is low because the compression algorithms are proprietary and not publicly available.|
|Self-documentation||RAR files contain supporting metadata in headers to easily identify and organizing the compressed files within.|
|External dependencies||RAR files can only be created by WinRAR software but can be opened in other tools (aside from WinRAR) including The Unarchiver, PeaZip, RAR Opener, 7-Zip and many others. The now-defunct unrarLib tool only works with RAR files up to version 2.|
|Technical protection considerations||RAR supports optional AES encryption, a type of block cipher which uses an algorithm that encrypts data on a per-block basis. There are various forms of the AES standard and the implementation used by RAR has changed with different versions of the format. RAR5 (current version as of this writing in March 2017) uses AES-256, a change from AES-128 used in RAR4.|
|Compression||RAR uses proprietary compression algorithms and the compression ratio is stored in the Compression Record tag in the file header.|
|Support for Error Dectection||RAR used optional CRC-32 hash values until RAR5 when the method switched to 56 bit length BLAKE2sp hash. In addition, RAR archives have an optional recovery record structure in the archive header.|
||For the data volume set|
||For the recovery volume set|
||According to Wikipedia, in early versions of the format, multi-volume files were split with the first file name .rar followed by .r01, .r02 etc.|
|Internet Media Type||application/x-rar-compressed
|Internet Media Type||application/vnd.rar
|File signature||See note.||Wikipedia states that RAR1.3 lacks a signature. Forensics Wiki states that "older versions of the RAR file format have a file signature of "52 45 7E 5E" but there is no documentation to support this. Comments welcome. See subtypes for details.|
||For RAR2. See http://www.nationalarchives.gov.uk/PRONOM/x-fmt/264|
||PRONOM labels this as RAR version 2.9 but other documentation including WinRAR 5.0 and RAR for Android refer to this version as RAR4. See http://www.nationalarchives.gov.uk/PRONOM/fmt/411|
||For RAR5. See http://www.nationalarchives.gov.uk/PRONOM/fmt/613|
|Wikidata Title ID||Q243303
||No version distinctions. See https://www.wikidata.org/wiki/Q243303.|
According to the RARLab website, RAR has several advantages over ZIP files including "more convenient multipart (multivolume) archives, tight compression including special solid, multimedia and text modes, strong AES-128 encryption, recovery records helping to repair an archive even in case of physical data damage, Unicode support to process non-English file names and a lot more." In addition, RAR archives usually provide a noticeably higher compression ratio than ZIP file format.