Posts and site content

Show the post title and other page data

Your theme fills in what Ghost knows about the page a reader opens. Use data blocks to show a post's title and date, a tag's name or an author's bio. To mix data with your own words in one sentence, type a value in curly brackets.

Add a data block

  1. Open your project in Fantasma.
  2. In the left sidebar, under Templates, click the template that shows the data, such as Post.
  3. In the Sections list, point at the row of the section that should show the data, such as Post Header, which holds the post's title and byline. Click the + at its right end. The block picker opens.
  4. Scroll the picker to the Data group, or type the block's name in its search field.
  5. Click the block you want, such as Date or Author. It appears at the end of the section and shows the value from the sample post on the canvas.
  6. Optional. To move the block, drag its row in the Sections list to where you want it.
The block picker opened from the Post Header row, scrolled to the Data group with Title, Excerpt, Featured Image, Date, Author and other data blocks

The picker offers the data blocks that the template has data for. The Post template offers the post's date and authors, and the Tag template offers the tag's post count. On the Homepage, data blocks appear only inside a post list, as Show a list of posts explains. A data block you move to a template without its data shows nothing there.

Title, Excerpt and Featured Image follow the page they are on:

Block On a post or page On a tag page On an author page
Title The title The tag's name The author's name
Excerpt The excerpt you wrote in Ghost Admin The tag's description The author's bio
Featured Image The feature image The tag's image The author's cover image

A data block whose value is empty in Ghost, such as an excerpt you never wrote, shows nothing on that post. Data blocks lists every data block and its settings. A post's tags are a Collection instead: click Post tags under Layout in the picker, as Show your tags or authors explains.

Change how a data block shows its value

Select the data block and look in the right sidebar. A few blocks have settings of their own:

  • Date: Format picks how the date reads, such as January 15, 2026 or 3 days ago. Theme default uses the Date format in Project settings › Features. Project settings opens from the project name at the top of the right sidebar.
  • Post Count: Number only shows "12" instead of "12 posts".
  • Title, Excerpt and Featured Image inside a post list: Make title a link, Make excerpt a link or Make image a link opens the post when a reader clicks it.

Each data block works like a plain block. Title is a heading, Date is a paragraph, and Featured Image is an image. You change their size and color under Typography and Colors in the right sidebar.

Put a value inside a sentence

To mix data with your own words, type its name in curly brackets into a heading or a paragraph. For example, type By {postAuthors} in {primaryTag} into a paragraph on the Post template. The canvas then shows "By Sarah Chen in Lifestyle", and every post shows its own authors and primary tag.

Some values to type:

You type Shows
{postTitle} The post's title
{postAuthors} The post's authors
{primaryTag} The post's primary tag
{readingTime} How long the post takes to read, such as "5 min read"
{tagName} The tag's name, on a tag page
{authorName} The author's name, on an author page

Page data variables lists every value and the templates that have it. A name must match exactly, capital letters included. A misspelled name stays in the text as you typed it, curly brackets and all.

When you type the closing bracket, the value turns into a small box with its name, such as Post authors. When you stop editing, the canvas shows the real value. The block's Text field in the right sidebar shows the same boxes. A dashed border and the tooltip "is not passed on this page" mean the value is unavailable where the block is placed.

On a template without that data, the value shows its name instead. {postTitle} on the Homepage reads "Post title", on the canvas and on your site. Type a value only on a template that has it. Inside a post list, a post value reads each post in the list, on any template.

Insert site details

The Insert data button in the text toolbar adds site details, dates and the page's URL where it is available.

  1. On the canvas, click the text once. Its block is selected.
  2. Click the text again, where the value goes. The cursor appears there.
  3. In the toolbar, click Insert data, the button with two curly brackets. A list opens with four suggestions. To see the rest, click the line that starts with Show all.
  4. Select the value, such as Site title or Current year.

The list holds Site title, Site description, Site URL, Current year, Current date and Current page URL. On the Error template, the list offers Status code and Error message instead of Current page URL. Post, tag and author values are not in this list. Add a data block to show one value. Type a value in curly brackets when you need it inside your own sentence.

You can also type these values, such as {currentYear}. A footer line such as "© {currentYear} {siteTitle}" keeps the year current with no edits. Edit text on the canvas explains the rest of the text toolbar.

Was this article helpful?