Apple Lossless, also known as Apple Lossless Audio Codec (ALAC), or Apple Lossless Encoder (ALE), is an audio codec developed by Apple Inc. for lossless data compression of digital music. After initially keeping it proprietary from its inception in 2004, in late 2011 Apple made the codec available open source and royalty-free. Traditionally, Apple has referred to the codec as Apple Lossless, though more recently they have begun to use the abbreviated term ALAC when referring to the codec.
Apple Lossless data is stored within an MP4container with the filename extension.m4a. This extension is also used by Apple for lossy AAC audio data in an MP4 container (same container, different audio encoding). However, Apple Lossless is not a variant of AAC (which is a lossy format), but rather a distinct lossless format that uses linear prediction similar to other lossless codecs. These other lossless codecs, such as FLAC and Shorten, are not natively supported by Apple's iTunes software (either the Mac OS or Windows versions) or by iOS devices, so users of iTunes software who want to use a lossless format which allows the addition of metadata (unlike WAV/AIFF or other PCM-type formats, where metadata is usually ignored) have to use ALAC. All current iDevices can play ALAC–encoded files. ALAC also does not use any DRM scheme; but by the nature of the MP4 container, it is thought that DRM could be applied to ALAC much the same way it can with 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. Furthermore, compared to many other formats, it is not as difficult to decode, making it practical for a limited-power device, such as iOS devices.
The 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 6.5.1 update; thus making it available in iTunes since version 4.5 and above. The codec is also used in the AirPort and AirPlay implementation.
The Apple Lossless Encoder (and decoder) were released as open source software under the Apache License version 2.0 on October 27, 2011., although an independent reverse-engineered open-source encoder and decoder were already available before the release.
David Hammerton and Cody Brocious have analyzed and decoded this codec without any documents on the format. On March 5, 2005, Hammerton published a simple open source decoder in the programming language C on the basis of the reverse engineering work.
^"iTunes Store: How to subscribe to iTunes Match". Apple Inc. January 16, 2012. Retrieved June 27, 2012. "Songs encoded in ALAC, WAV, or AIFF will be transcoded to a separate temporary AAC 256 kbps file locally, prior to uploading to iCloud. The original files will remain untouched."