GPDoc logoGPDoc
Docs
Document Suite

Create structured documents and templates

Use Markdown, file data, variables, themes, and embedded GPDoc files to build reusable documents.

GPDoc documents stay readable as Markdown while adding file-scoped data, variables, themes, and embedded GPDoc content. This makes one source useful for a report, proposal, release brief, or another repeatable document.

Add data and variables

Open View > Data & Variables. Enter a JSON object or a JavaScript expression that returns an object. Nested objects and arrays are supported.

{
  "customer": {
    "name": "Northwind Labs",
    "plan": "Pro"
  },
  "report": {
    "period": "Q3 2026",
    "owner": "Morgan Lee"
  },
  "generatedAt": "(() => new Date().toISOString())"
}

Reference the data from Markdown with braces:

# {{ customer.name }} review

**Period:** {{ report.period }}
**Owner:** {{ report.owner }}
**Plan:** {{ customer.plan }}

GPDoc resolves paths such as {{ customer.name }} from the open file's data. The optional data. prefix works as well.

Apply a document theme

Open View > Theme & Design to set file-level design tokens for color, typography, layout, tables, and lists. The theme changes how the document is rendered without replacing the Markdown source.

Embed another GPDoc

Use Insert > Embed GPDoc File and select a document or slide deck. GPDoc inserts a reference such as:

<gpdoc document="file:shared-header-file-id"></gpdoc>

The referenced file must remain available to the current GPDoc workspace for preview and export. An embedded file owns its own data and theme. Parent variables are not automatically passed into it.

Build a template with a shared header

Create a small GPDoc document with the organization name, logo, contact line, or standard legal text. Apply its own theme and data when the header needs variables.

Create a second document and add fields such as {{ customer.name }}, {{ report.period }}, and {{ report.owner }} through View > Data & Variables.

Place the cursor at the start of the body document and choose Insert > Embed GPDoc File. Select the shared header.

Create a copy of the body document, update its file-scoped data, and keep the header reference intact. Changes to the shared header appear when the referenced file can still be resolved.

File boundary

The body template and shared header do not share one automatic data context. Put body variables in the body file and header variables in the header file.

Comments, suggestions, version history, Git, and export remain available around the structured source. Review the output before publishing because destination formats can render fonts, spacing, or embeds differently.

Review export and publishing paths.

Next guide

Export, share, and publish GPDoc files

Use the File menu to create local files, send provider copies, share with collaborators, save to GitHub, or publish a website.