Skip to content

MPEG-4 Advanced Audio Coding (.aac)

.aac file signature | audio/x-aac

MPEG-4 Advanced Audio Coding (AAC) Low Complexity (LC) audio file

Safe

Magic Bytes

Offset 0
49 44 33

Sources: Apache Tika

All Known Signatures

3 signature variants are documented for .aac files across multiple sources.

Hex Signature Offset Sources
49 44 33 0 Apache Tika
FF F1 0 Gary Kessler
FF F9 0 Gary Kessler

Extension

.aac

MIME Type

audio/x-aac

Byte Offset

0

Risk Level

Safe

Validation Code

How to validate .aac files in Python

Python
def is_aac(file_path: str) -> bool:
    """Check if file is a valid AAC by magic bytes."""
    signature = bytes([0x49, 0x44, 0x33])
    with open(file_path, "rb") as f:
        return f.read(3) == signature

How to validate .aac files in Node.js

Node.js
function isAAC(buffer: Buffer): boolean {
  const signature = Buffer.from([0x49, 0x44, 0x33]);
  return buffer.subarray(0, 3).equals(signature);
}

How to validate .aac files in Go

Go
func IsAAC(data []byte) bool {
    signature := []byte{0x49, 0x44, 0x33}
    if len(data) < 3 {
        return false
    }
    return bytes.Equal(data[:3], signature)
}

API Endpoint

GET /api/v1/aac
curl https://filesignature.org/api/v1/aac

See the full API documentation for all endpoints and parameters.

Frequently Asked Questions

What is a .aac file?

A .aac file is a MPEG-4 Advanced Audio Coding file. MPEG-4 Advanced Audio Coding (AAC) Low Complexity (LC) audio file

What are the magic bytes for .aac files?

The magic bytes for MPEG-4 Advanced Audio Coding files are 49 44 33 at byte offset 0. These bytes uniquely identify the file format regardless of the file extension.

How do I validate a .aac file?

To validate a .aac file, read the first bytes of the file and compare them against the known magic bytes (49 44 33) at offset 0. This is more reliable than checking the file extension alone, as extensions can be renamed.

What is the MIME type for .aac files?

The primary MIME type for .aac files is audio/x-aac.

Is it safe to open .aac files?

MPEG-4 Advanced Audio Coding (.aac) files are generally safe to open. They are classified as low risk because they primarily contain data rather than executable code. However, always ensure files come from a trusted source.