What is the EDF file format?
.edf (European Data Format) is an open standard for exchanging and storing multichannel time-series biosignals - EEG, EMG, ECG, and polysomnography recordings. Developed by Bob Kemp and colleagues and first published in 1992, it was designed as a simple, application-independent way to share physiological recordings between hospitals and research groups worldwide.
Each .edf file has a header section that contains file metadata: patient identification, recording date and time, the number of signals, and per-channel information including physical and digital scaling ranges and sample rates. The second part of the file contains the biosignal data in binary format as 16-bit signed integers, organized in fixed-length data records. Files begin with the 8-byte ASCII field "0 " (the digit zero followed by seven spaces) - the format's identifying magic signature.
EDF is an open, non-proprietary format with its specification published freely. An updated version, EDF+, adds some new features - annotations, event markers, and discontinuous recordings - but still uses the same .edf extension. The related BDF format is a 24-bit variant used by BioSemi amplifiers, while GDF (General Data Format) extends EDF with a richer header.
The format is widely supported in clinical and research software including EDFbrowser, MNE-Python, EEGLAB, and FieldTrip. Some files, particularly from older polysomnography recorders, carry the .rec extension instead.
Security & safety
RISK: LOWAn .edf is passive measurement data and cannot execute, so it's safe to open in a viewer. The real concern is privacy: clinical EDF/EDF+ headers can contain patient name, ID, and recording date - treat medical recordings as sensitive personal data and anonymize (EDFbrowser can blank the patient fields) before sharing. If a text editor shows only gibberish after the readable header, that's normal (the signal body is binary) - or you may actually have the unrelated RF Online / ESRF kind of .edf, which needs different software.
Format details
in a nutshell- RF Online game data file - Some installs of the MMORPG RF Online use .edf files for game data; opened only by the game, not by biosignal tools.
- ESRF Data Format (EDF image) - The European Synchrotron (ESRF) stores 2D detector images as .edf (ASCII header + binary pixels), read by Fit2D / silx / SAXS tools.
Programs that open EDF files
Technical details
deep spec| File structure | 256-byte global ASCII header + 256 bytes per signal × number of signals, followed by contiguous binary data records |
| Sample encoding | 16-bit signed integers, little-endian, one value per sample per channel |
| Header encoding | Pure ASCII; all header fields are fixed-width and space-padded - no null bytes appear anywhere in the header |
| Magic bytes | 0x30 followed by seven 0x20 bytes at offset 0 - ASCII "0 " (digit zero followed by seven spaces) |
| MIME type | application/octet-stream |
| Signal types supported | EEG, EMG, ECG, EOG, body temperature, blood oxygen, respiratory effort, and arbitrary time-series biosignals |
| Channels per file | Up to 9,999 signals; each channel independently defines its own sampling rate and physical unit |
| Per-channel header fields | Signal label, transducer type, physical dimension (unit), physical min/max, digital min/max, prefiltering info, samples per data record |
| Physical-to-digital mapping | Linear scaling defined per channel by (digital_min, digital_max, physical_min, physical_max); resolution = (physical_max − physical_min) / 65536 |
| EDF+ annotation track | Reserved channel labelled "EDF Annotations" stores TAL (Time-stamped Annotations Lists) as UTF-8 text events with onset, duration, and description |
| Discontinuous recording | Base EDF requires continuous data; EDF+ adds EDF+C (continuous) and EDF+D (discontinuous) subtypes flagged in a reserved header field |
| Alternate extension | .rec - used by some older polysomnography recorders for files in the identical EDF binary format |
| Related formats | BDF (24-bit BioSemi variant, magic 0xFF + "BIOSEMI"); GDF v1/v2 (General Data Format, backward-compatible superset of EDF) |
| Software support | EDFbrowser, MNE-Python, EEGLAB, FieldTrip, Polyman, BrainVision Analyzer (import), MATLAB Biosig toolbox |
| Released | 1992 (EDF); EDF+ in 2003 |
| Open standard | Yes · royalty-free |
| Specification | www.edfplus.info |
EDF conversions
Community Q&A
asked by usersNo questions yet - be the first to ask about EDF files.