Adding Mastodon author attribution to Ghost
How to add the Mastodon author attribution to your single author Ghost site.
With the release of Mastodon 4.3, the federated social platform now supports authorship attribution. It's a method of highlighting an article's author when the article is shared on Mastodon. The author's name becomes a clickable link to their Mastodon account, hopefully leading to an uptick in followers:
In this version we’re introducing a new way to highlight writers and journalists on the fediverse. By adding a single line to their HTML, publishers can feature the fediverse profile of the page author in the link previews on Mastodon. That way, when lots of different people are sharing the link, or the link is trending in the News tab, you can easily navigate to the author’s fediverse profile and follow them right from within Mastodon to receive future updates. Publications like The Verge and TechCrunch are already using this.
This is what it looks like:
And here's how I set it up, based on this guide.
The Ghost end
So, first things first:
- Head to your Ghost settings and search for “Code Injection”
- In the Head section paste in the following code:
<meta name="fediverse:creator" content="@adders@masto.onemanandhisblog.com" />
(Make sure to replace my Mastodon account with yours…)
Hit save, and you're done.
The Mastodon end
Then, you're off to your Mastodon settings. This will only work if your instance has been upgraded to Mastodon 4.3 or above.
- Go to Settings -> Profile -> Verification
- Add the domain you've added the metadata to in the Author attribution box at the bottom.
- Hit save.
You're all done. In future, any article you — or anyone else — shares on Mastodon will have a neat, clickable author link that brings the readers straight to your Mastodon profile, where they can follow you.
Mastodon clients apps will need to support it too. But some already do. For example, this is how it looks in Ivory, my preferred iOS Mastodon client:
That said, it's probably better to wait to see how the Ghost Activity Pub implementation works out, as it might cover much of this.
Sign up for e-mail updates
Join the newsletter to receive the latest posts in your inbox.