The Apple Lossless Audio Codec (ALAC), also known as Apple Lossless, or Apple Lossless Encoder (ALE), is an
audio coding format
An audio coding format (or sometimes audio compression format) is a content representation format for storage or transmission of digital audio (such as in digital television, digital radio and in audio and video files). Examples of audio coding ...
, and its reference
audio codec
An audio codec is a device or computer program capable of encoding or decoding a digital data stream (a codec) that encodes or decodes audio. In software, an audio codec is a computer program implementing an algorithm that compresses and decompres ...
implementation, developed by
Apple Inc. for
lossless data compression
Lossless compression is a class of data compression that allows the original data to be perfectly reconstructed from the compressed data with no loss of information. Lossless compression is possible because most real-world data exhibits statist ...
of digital
music
Music is generally defined as the The arts, art of arranging sound to create some combination of Musical form, form, harmony, melody, rhythm or otherwise Musical expression, expressive content. Exact definition of music, definitions of mu ...
. After initially keeping it
proprietary from its inception in 2004, in late 2011 Apple made the codec available
open source
Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use the source code, design documents, or content of the product. The open-source model is a decentralized sof ...
and
royalty-free
Royalty-free (RF) material subject to copyright or other intellectual property rights may be used without the need to pay royalties or license fees for each use, per each copy or volume sold or some time period of use or sales.
Computer standard ...
. Traditionally, Apple has referred to the codec as ''Apple Lossless'', though more recently it has begun to use the abbreviated term ''ALAC'' when referring to the codec.
Codec
ALAC supports up to 8 channels of audio at 16, 20, 24 and 32 bit depth with a maximum sample rate of 384 kHz.
ALAC data is frequently stored within an
MP4 container with the
filename extension
A filename extension, file name extension or file extension is a suffix to the name of a computer file (e.g., .txt, .docx, .md). The extension indicates a characteristic of the file contents or its intended use. A filename extension is typically ...
''
.m4a
MPEG-4 Part 14 or MP4 is a digital multimedia container format most commonly used to store video and audio, but it can also be used to store other data such as subtitles and still images. Like most modern container formats, it allows streami ...
''. This extension is also used by Apple for lossy AAC audio data in an MP4 container (same container, different audio encoding). The codec can also be used by the
.CAF file type container, though this is much less common.
ALAC is not a variant of
AAC (which is a
lossy format), but rather an unrelated lossless format that uses
linear prediction (similar to other lossless codecs).
ALAC also does not use any
DRM scheme; but by the nature of the MP4
container, it is feasible that DRM could be applied to ALAC much in the same way it is applied to files in other QuickTime containers.
According to Apple, audio files compressed with its lossless codec will use up "about half the storage space" that the uncompressed data would require. Testers using a selection of music have found that compressed files are about 40% to 60% the size of the originals depending on the kind of music, which is similar to other lossless formats.
ALAC has been measured to require around four times as much CPU power to decode than FLAC does,
with implications for battery life on limited-power devices. Still the format has been recommended for older
iPod
The iPod is a discontinued series of portable media players and multi-purpose mobile devices designed and marketed by Apple Inc. The first version was released on October 23, 2001, about months after the Macintosh version of iTunes ...
devices based on claims of lower power usage.
Partly because of the use of an MP4 container, ALAC does not contain integrated error checking.
History
The
data compression
In information theory, data compression, source coding, or bit-rate reduction is the process of encoding information using fewer bits than the original representation. Any particular compression is either lossy or lossless. Lossless compressi ...
software for encoding into ALAC files, Apple Lossless Encoder, was introduced into the Mac OS X
Core Audio framework on April 28, 2004, together with the
QuickTime
QuickTime is an extensible multimedia framework developed by Apple Inc., capable of handling various formats of digital video, picture, sound, panoramic images, and interactivity. Created in 1991, the latest Mac version, QuickTime X, is a ...
6.5.1 update, thus making it available in
iTunes since version 4.5 and above, and its replacement, the Music application.
The codec is also used in the
AirPort
An airport is an aerodrome with extended facilities, mostly for commercial air transport. Airports usually consists of a landing area, which comprises an aerially accessible open space including at least one operationally active surfa ...
and
AirPlay
Airplay is how frequently a song is being played through broadcasting on radio stations. A song which is being played several times every day ( spins) would have a significant amount of airplay. Music which became very popular on jukeboxes, in ...
implementation.
David Hammerton and
Cody Brocious analyzed and
reverse engineered the codec without any documents on the format. On March 5, 2005, Hammerton published a simple
open source
Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use the source code, design documents, or content of the product. The open-source model is a decentralized sof ...
decoder written in the
C programming language
''The C Programming Language'' (sometimes termed ''K&R'', after its authors' initials) is a computer programming book written by Brian Kernighan and Dennis Ritchie, the latter of whom originally designed and implemented the language, as well as ...
on the basis of the work.
The Apple Lossless Encoder (and decoder) were released as open source software under the
Apache License version 2.0 on October 27, 2011.
On May 17, 2021, Apple announced that they would begin offering lossless audio in
Apple Music
Apple Music is a music, audio and video streaming service developed by Apple Inc. Users select music to stream to their device on-demand, or they can listen to existing playlists. The service also includes the Internet radio stations Apple ...
in June 2021, with all lossless music being encoded using ALAC.
Apple support for lossless formats
Other lossless codecs, such as
FLAC
FLAC (; Free Lossless Audio Codec) is an audio coding format for lossless compression of digital audio, developed by the Xiph.Org Foundation, and is also the name of the free software project producing the FLAC tools, the reference software p ...
and
Shorten, are not natively supported by Apple's
iTunes nor the later
Music app (either the macOS or Windows versions) or by
iOS devices running
iOS 10 or below. In order to be played through the iTunes and Music app on iOS, audio files using these lossless codecs may be converted via various
third-party tools into ALAC-encoded files with no change in fidelity.
Third-party applications are available from the
App Store to play such files without converting them. Devices running
iOS 11 or above do support FLAC playback natively, through the
Files
File or filing may refer to:
Mechanical tools and processes
* File (tool), a tool used to ''remove'' fine amounts of material from a workpiece
**Filing (metalworking), a material removal process in manufacturing
** Nail file, a tool used to gent ...
application only.
The method of importing the files to the Apple device varies between applications, including Files, as there is currently no official support for doing so.
Software
All current iOS devices can play ALAC encoded files.
The open source library
libavcodec
libavcodec is a free and open-source library of codecs for encoding and decoding video and audio data.
libavcodec is an integral part of many open-source multimedia applications and frameworks. The popular MPV, xine and VLC media players u ...
incorporates both a decoder and an encoder for the ALAC format, which means that
media players based on that library (including
VLC media player and
MPlayer
MPlayer is a free and open-source media player software application. It is available for Linux, OS X and Microsoft Windows. Versions for OS/2, Syllable, AmigaOS, MorphOS and AROS Research Operating System are also available. A port for ...
, as well as many media center applications for
home theater computers, such as
Plex,
XBMC, and
Boxee) are able to play ALAC files.
As of 2015,
Windows 10
Windows 10 is a major release of Microsoft's Windows NT operating system. It is the direct successor to Windows 8.1, which was released nearly two years earlier. It was released to manufacturing on July 15, 2015, and later to retail on ...
includes support for ALAC encoding and decoding, thereby enabling other media players to use it, e.g.
Windows Media Player
Windows Media Player (WMP) is the first media player and media library application that was developed by Microsoft for playing audio, video and viewing images on personal computers running the Microsoft Windows operating system, as well as ...
when ripping CDs or the
Spotify
Spotify (; ) is a proprietary Swedish audio streaming and media services provider founded on 23 April 2006 by Daniel Ek and Martin Lorentzon. It is one of the largest music streaming service providers, with over 456 million monthly active us ...
desktop client for playback of local .m4a files.
The library was subsequently optimized for ARM processors and included in
Rockbox.
Foobar2000 will play ALAC files as will
JRiver Media Center and BitPerfect.
Lossless music via ALAC was added to
Apple Music
Apple Music is a music, audio and video streaming service developed by Apple Inc. Users select music to stream to their device on-demand, or they can listen to existing playlists. The service also includes the Internet radio stations Apple ...
in June 2021, at no additional cost for all subscribers. The maximum fidelity for lossless music on Apple Music is 24-bit at 192 kHz.
See also
*
Audio Interchange File Format (AIFF)
*
Comparison of audio coding formats
The following tables compare general and technical information for a variety of audio coding formats.
For listening tests comparing the perceived audio quality of audio formats and codecs, see the article Codec listening test.
General informati ...
*
Free Lossless Audio Codec (FLAC)
*
Monkey's Audio
*
TTA
*
WavPack
*
Windows Media Audio 9 Lossless
References
External links
ALAC Projectat MacOSForge
ALACtechnical features at MacOSForge
ALACimporting at
Apple
An apple is an edible fruit produced by an apple tree (''Malus domestica''). Apple trees are cultivated worldwide and are the most widely grown species in the genus '' Malus''. The tree originated in Central Asia, where its wild ances ...
ALAC compression rates for different types of musicarticle by Kirk McElhern
{{Apple
Free audio codecs
Lossless audio codecs
Formerly proprietary software
IPod
ITunes
Lossless
Lossless compression is a class of data compression that allows the original data to be perfectly reconstructed from the compressed data with no loss of information. Lossless compression is possible because most real-world data exhibits statistic ...
Open file formats
Software using the Apache license