.AR

AR File

Unix ar Archive
Ask a question
QUICK ANSWER

An AR file is a Unix/Linux archive - a flat container that stores multiple files, most commonly compiled object files bundled into a static library. On Linux and macOS, extract it with the built-in ar command (ar x file.ar). On Windows, use 7-Zip. The format applies no compression and has no directory structure.

Developer: Bell Labs / various Unix vendors; GNU binutils ar (most common implementation) Category: Compressed Files Open standard MIME: application/x-archive
OPENS ON Windows macOS Linux
Related: .RAR · .ZIP · .Z01 · .7Z

On this page

19k+ extensions indexed
Last reviewed Aug 27, 2026

Not sure what your file is?

Drop any file into our identifier - we read just the first bytes to name the format.

Identify a file

What is the AR file format?

The .ar archive format dates back to Unix Version 1 (1971), created at Bell Labs as the original Unix archiver. An .ar file concatenates multiple member files, each preceded by a fixed 60-byte ASCII header recording the member's name, modification time, permissions and byte size. Every archive begins with the 8-byte magic string !<arch> followed by a single line feed (0x0A).

The format stores members uncompressed by default. Two main variants exist:

  • The BSD variant (used on macOS) extends long filenames inline after each member header.
  • The System V/GNU variant (used on Linux) stores long names in a special // member and prepends a / symbol index entry for efficient link-time lookup.

Today .ar is most commonly encountered as .a static libraries on Linux and macOS, where the ar tool from GNU binutils is the standard implementation. Debian .deb packages are also ar archives - renaming a .deb and extracting it reveals the inner control.tar and data.tar members. Common ar commands: ar rcs libfoo.a *.o creates an archive, ar t archive.ar lists members, and ar x archive.ar extracts them.

Security & safety

RISK: LOW

AR archives themselves are containers with no executable semantics - they cannot auto-run code. However, the members inside may be compiled object files or executables that could be malicious. When extracting an ar archive from an untrusted source, inspect the extracted files before executing them. Static libraries linked into your binaries become part of those binaries; a tampered static library is a supply- chain attack vector (e.g. compromised toolchain archives). Always verify checksums when downloading toolchain tarballs containing .a/.ar libraries.

Format details

in a nutshell
FULL NAMEUnix ar Archiveaka static library archive, Unix archiver file
DEVELOPERBell Labs / various Unix vendors; GNU binutils ar (most common implementation)since 1971 (Unix v1, as the original Unix archiver)
MIME TYPEapplication/x-archive
TYPEflat archive (not compressed by default)
STANDARDOpen · royalty-free
This extension is also used by…
  • Debian package (.deb) - A .deb file is an ar archive containing control.tar.* and data.tar.* members; the ar container is transparent to end users (dpkg handles it).
  • .a static library (same format, different extension) - On Linux/macOS .a is the conventional extension for static libraries in ar format; .ar is less common but identical.
MAGIC BYTES · FILE SIGNATURE
OFFSET
0001020304050607
HEX
213C617263683E0A
ASCII
!<arch>·
The global header is the ASCII string "!<arch>" followed by a single LF (0x0A). Every ar archive starts with exactly these 8 bytes. GNU thin archives use "!<thin>" (0x21 3C 74 68 69 6E 3E 0A) instead.

Programs that open AR files

Windows3 apps
7-Zip Open-source Right-click > 7-Zip > Extract Here. GUI and command-line both support ar archives.
GNU ar (via MinGW-w64 / WSL) Open-source In WSL (Windows Subsystem for Linux) or MinGW/MSYS2: ar x file.ar. Needed when working with cross-compilation toolchains.
GNU project C (GCC via MinGW) Open-source GCC toolchain includes ar; use ar x to extract or ar r to add members.
macOS2 apps
macOS (llvm-ar / Xcode Command Line Tools) Free ar is pre-installed on macOS. Terminal: ar x file.ar to extract; ar t file.ar to list. Xcode CLT provides llvm-ar.
GNU ar (via Homebrew) Open-source brew install binutils then use gar (GNU ar) for full GNU compatibility.
Linux3 apps
GNU ar (binutils) Open-source Built-in on all Linux distros. ar t file.ar (list contents); ar x file.ar (extract all); ar r file.ar obj.o (add a member).
7-Zip / p7zip Open-source 7z l file.ar to list; 7z x file.ar to extract. GUI available via p7zip-gui on some distros.
Linux operating systems (built-in ar) Open-source ar command is pre-installed; use ar x to extract members.

Technical details

deep spec
Magic bytes21 3C 61 72 63 68 3E 0A - ASCII string !<arch> plus newline (0x0A) at offset 0
MIME typeapplication/x-archive
Per-member header size60 bytes (fixed-width, ASCII-encoded fields)
Header field layoutFilename 16 B, modification time 12 B, UID 6 B, GID 6 B, mode 8 B, size 10 B, magic 2 B
Member alignment2-byte boundary; odd-length members padded with a single newline character (0x0A)
CompressionNone by default - member files stored verbatim and uncompressed
Integrity checkingNo per-member or archive-level checksums in the ar format
Filename limit16 chars in fixed header; unlimited via BSD inline extension or System V // member table
Format variantsBSD (macOS): inline extended names; System V/GNU (Linux): // member table for long names
GNU symbol indexGNU ar prepends a / symbol table member to .a archives for efficient link-time symbol lookup
Thin archive supportGNU thin archives use magic 21 3C 74 68 69 6E 3E 0A (!<thin>) and store file paths, not data
Primary uses.a static libraries (Linux, macOS), .deb Debian packages, .ipk OpenWrt packages
PlatformsLinux, macOS, FreeBSD, Solaris, AIX, Windows (MinGW/Cygwin/WSL)
Released1971 (Unix v1, as the original Unix archiver)
Latest versionPOSIX.1-2017 specifies the format; GNU ar (binutils) is current implementation
Open standardYes · royalty-free
Specificationpubs.opengroup.org

Community Q&A

asked by users
Ask a quick question
Get help from people who work with AR files. Be specific - include your system and software version.
No account needed · answers usually within a day

No questions yet - be the first to ask about AR files.

Frequently asked questions

How do I extract files from an AR archive?
On Linux/macOS: open a terminal and run 'ar x filename.ar' to extract all members. On Windows, use 7-Zip (right-click > Extract Here). On Linux, ar is part of the pre-installed binutils package.
What is an AR file?
A Unix archive - a flat container of files, most commonly used to bundle compiled object files into a static library (.a). It is also the outer container for Debian .deb packages.
How do I list the contents of an AR archive?
On Linux/macOS: 'ar t filename.ar' lists all member names. With 7-Zip on Windows: '7z l filename.ar'.
Is an AR file a compressed archive like ZIP?
No - ar applies no compression. Members are stored as-is, concatenated with metadata headers. For compression, the member data must be compressed separately (as in .deb, where tar members inside ar are compressed).
What is the difference between .ar and .a files?
They are the same format. .a is the conventional extension for static libraries on Linux/macOS; .ar is a less common alternative name for the same format.
Can I open an AR file on Windows?
Yes - 7-Zip (free) opens ar archives on Windows. If you need the ar command itself, install MinGW-w64 or use WSL (Windows Subsystem for Linux).

References

1Wikipedia - ar (Unix)en.wikipedia.org
2GNU Binutils - ar manualsourceware.org

Keep exploring

across the database

Top extensions this week

1.AQQAQQ Instant Messenger File
2.CRDOWNLOADChrome Partial Download File
3.MDMarkdown Document
4.BINCD/DVD Disc Image (BIN/CUE)
5.NOMEDIAAndroid No-Media Marker File
6.PARTPartial Download File
7.RPMSGRestricted Permission Message
8.EXEWindows Executable (Portable Executable)
9.AVIFAV1 Image File Format (AVIF)
10.DBSQLite Database File

Related extensions

.RARRAR Archive (Roshal ARchive)
.ZIPZIP Archive
.Z01Split ZIP Archive - First Part
.7Z7-Zip Archive
.001Split / multi-volume archive - first part (.001)
.ZIRenamed / Truncated ZIP Archive

Free file tools

An in-browser file identifier and image converter - everything runs on your device.

Open the toolbox

Browse file extensions A-Z