TEI Primer

This primer contains tutorials that focus on building a knowledge of the TEI from the very basics to more advanced markup concepts. We recommend starting here if you are new to the TEI. The primer begins with a preliminary explanation of the mechanics of XML. Following this introduction, we cover the reasons one might want to use XML—or, more specifically, TEI encoding. Moving from the conceptual realm, the tutorials cover how to mark up basic structural and phrase-level textual features using the TEI as well as more advanced encodings, such as marking rendition, images, notes, and handwritten additions. This primer also contains tutorials that provide overviews of metadata and TEI customization.

This primer is great for those learning TEI for the first time. If you are considering using TEI on your project, begin here.

Set-up for Tutorials

Before you begin, see our tutorial set-up page. This provides instructions on working in oXygen XML Editor, downloading the files for hands-on exercises, and using the tutorials.

An introduction to XML

This tutorial outlines the fundamental rules of XML, what XML is, and how it relates to the TEI. This tutorial will also explain why your project may want to use XML, as opposed to some other type of markup system.

Get started

Overview of Text Encoding and the TEI

This tutorial contains an overview of the TEI within the context of the larger field of digital humanities. We explain the rationale behind scholarly text encoding, and discuss why you may want to use TEI on your project.

Get started

Basic Tagging

This tutorial explains the basic elements used to encode a TEI document, focusing on the fundamental structural elements for marking up your text (in particular, for basic prose, poetry, and drama). Building from these foundational elements, the tutorial covers phrase-level elements, like names, references, and linguistic features. These slides also cover: how to correct, regularize, or modernize the text, while still acknowledging the original; how to encode authorial or editorial deletions and revisions of the text; and how to show uncertainty about your reading of the text.

After completing this tutorial, you may be interested in the following tutorials not included in this primer:

  • Basic Manuscript Encoding: This tutorial tackles the basic elements used to encode a TEI document, with a particular focus on the encoding of manuscripts.
  • Encoding Contextual Information: This tutorial outlines the TEI’s mechanism for contextual encoding, providing information on how to create structured data about certain things contained within your texts—persons, places, organizations, etc.—using TEI elements.

Get started

Advanced Markup Concepts

This tutorial builds upon the basic encoding tutorial to cover topics such as how to demonstrate connections between various parts of the text—such as a note and the material it is annotating—through linking. This tutorial also covers: displaying page images (facsimiles) with your markup; linking between fragmented textual features (i.e. features where your markup and the textual divisions don’t line up perfectly); and encoding the appearance of the text (through marking changes in rendition and handwritten additions).

After completing this tutorial, you may be interested in the following tutorials not included in this primer:

  • Basic Manuscript Encoding: This tutorial tackles the basic elements used to encode a TEI document, with a particular focus on the encoding of manuscripts.
  • Advanced Manuscript Encoding: This tutorial is particularly important to those who want to encode manuscripts; it builds on the basic encoding tutorial with a particular focus on the encoding of manuscripts.
  • Encoding Contextual Information: This tutorial outlines the TEI’s mechanism for contextual encoding, providing information on how to create structured data about certain things contained within your texts—persons, places, organizations, etc.—using TEI elements.

Get started

Metadata and the TEI Header

This tutorial describes the types of contextual information (or metadata) that one might want to provide for an encoded document. Metadata is important for many audiences of encoded documents because it can provide information that may not be explicit in the text itself. For example, one might include metadata about the birth and death dates of people in a historical novel, or provide contextual information about the publishers of a given book. This tutorial covers the basic mechanisms the TEI provides for encoding such information; metadata and the encoding of other contextual information are covered more extensively in the Contextual Encoding Primer.

Get started

Customization and the TEI

This tutorial provides a very brief overview of TEI customization: what it is and why one might want to do it. You should use this tutorial if you are new to TEI customization and wondering if your project might benefit from customizing the TEI. Customization is covered in greater detail in the Customization Primer.

Get started

What next?

If you have finished this primer, you might be wondering where to go next. Listed below are brief descriptions of the primers that assume the basic knowledge of XML and TEI provided in this TEI Primer. You can also return to the Tutorial Curriculum Page for full descriptions of all the primers.