A GEDCOM file consists of a
header section, records, and a
trailer section. Within these sections,
records represent people (INDI record), families (FAM records), sources of information (SOUR records), and other miscellaneous records, including notes. Every line of a GEDCOM file begins with a level number where all top-level records (HEAD, TRLR, SUBN, and each INDI, FAM, OBJE, NOTE, REPO, SOUR, and SUBM) begin with a line with level 0, while other level numbers are positive
integers. Although it is possible to write a GEDCOM file by hand, the format was designed to be used with software and thus is not especially human-friendly. A GEDCOM validator that can be used to validate the structure of a GEDCOM file is included as part of
PhpGedView project, though it is not meant to be a standalone validator. For standalone validation "The Windows GEDCOM Validator" can be used. or the older unmaintained Gedcheck from the LDS Church. During 2001,
The GEDCOM TestBook Project evaluated how well four popular genealogy programs conformed to the GEDCOM 5.5 standard using the Gedcheck program. Findings showed that a number of problems existed and that "The most commonly found fault leading to data loss was the failure to read the NOTE tag at all the possible levels at which it may appear." In 2005, the
Genealogical Software Report Card was evaluated (by Bill Mumford who participated in the original
GEDCOM Testbook Project) and included testing the GEDCOM 5.5 standard using the Gedcheck program. To assist with adoption of GEDCOM 7.0, validation tools now exist for that standard as well.
Example The following is a sample GEDCOM file. The header (HEAD) includes the source program and version (Personal Ancestral File, 5.0), the GEDCOM version (5.5), the
character encoding (
ANSEL), and a link to information about the submitter of the file. The individual records (INDI) define John Smith (ID I1), Elizabeth Stansfield (ID I2), and James Smith (ID I3). The family record (FAM) links the husband (HUSB), wife (WIFE), and child (CHIL) by their ID numbers. ==Versions==