-
Mo
chevron_right
The difference between XMPP and ActivityPub, explained through the Blog feature
️
Timothée Jaussoin • pubsub.movim.eu / Movim • Yesterday - 21:03 • 8 minutes
Blogs are one of the historical features of Movim, the upcoming 0.32 release will redefine how you interact with them and how you can follow them.
In this short article you'll discover how they are handled in #Movim by also learning the particularities of the #XMPP Network compared to the #Fediverse one.
XMPP and ActivityPub: Two Different Approaches
Movim is only relying on the XMPP #protocol to store and exchange the information it manages. When you authenticate with your account (for example, john@movim.eu), Movim will directly connect to your XMPP server (movim.eu in our example) and will then provide a complete social and chat experience on top of it. Everything you will do will be stored on it: chat messages, uploaded files, profile pictures, publications and many other things.
It is then the role of your XMPP server to contact the other servers to spread and receive the information to your contacts and followers.

This architecture is completely different than on the Fediverse (the federated network that is built on the #ActivityPub protocol). In the Fediverse each platform has a specific role (microblogging, picture sharing, publishing and watching videos), and you have to create an account on each of them to use their respective features.
Work is then done by the developers between each of those platforms (Peertube ActivityPub documentation, Mastodon ActivityPub documentation...) to try to standardize their interactions with the others on top of some generic protocols.

In XMPP clients and servers developers are standardizing together the concepts and interactions they want to manage in extensions (called XEPs) before or during their integrations and those concepts are made generic enough to be directly handled easily by the other projects.
For example, there is an #XEP to manage your chat messages history, XEP-0313: Message Archive Management, there is another XEP that explains how you can bookmark and synchronize chatrooms XEP-0402: PEP Native Bookmarks, another one that defines how you can publish Stories XEP-0501: Pubsub Stories, there is one that shows how clients handles emoji reactions bellow chat messages XEP-0444: Message Reactions...
We have today more than 500 XEPs that standardize most of the core features of all the social interactions we can have online. And we are working actively on what is missing. 😉
You can see the complete list on the XMPP Software Foundation website. One useful feature is that by clicking on the buttons on the right column you can see which clients and servers are actually implementing them! It's super useful when you want to integrate one in your own project and you want to test the integration with the others. 🤩

So! It means that the Prosody, Tigase, MongooseIM, OpenFire, ejabberd XMPP servers (yes there are many of them already) that host the millions of accounts, including yours (movim.eu is using ejabberd) can already allow you to do microblogging, publish long articles, photos, messages, do video-conferencing... out of the box. How convenient! ✨
It is then the role of the clients that connect to it to offer a "view" on those features. And Movim is one of those clients. To say it differently, Movim (like all the other XMPP clients) stores no important information; it just caches and displays what it found on the network.
Blogs, a simple news feed on your XMPP account
In Movim blogs are not different from all the features above. They were historically defined in 2008 in an XEP called XEP-0277: Microblogging over XMPP that evolved in 2022 into XEP-0472: Pubsub Social Feed.
This new XEP clarifies and generalizes some concepts of XEP-0277 but the core idea stays the same:
- An XMPP account or an XMPP service (a subpart of an XMPP server) can host nodes.
- Accounts can follow those nodes.
- Accounts can publish items on those nodes.
- Items that are published on those nodes are articles that can have different forms but are all valid Atom 1.0 elements (yes the same thing you can find in the RSS/Atom feeds online, we are not reinventing things, just reusing widely available technologies 😜.)
So what is a blog then?
A blog is a node, hosted on your own account, managed by you, where you can publish short articles (called "Briefs" in Movim) or very long ones (like this one ☺️) in the form of Atom 1.0 elements that people can follow!
When you publish a new article on your blog Movim will then simply send it to your XMPP server and store it in your own personal blog node linked to your account. Your friends that follow it will then receive a notification that a new article was published. And... that's it!
So how can I publish an article on my blog?
Some of the Movim users are sometimes asking, "But where is the API to publish blog posts?" Our API is the XMPP standard 😸! By just reading the XEP and using one of the many clients or libraries (that are available in all the main programming languages), you will be able to publish articles in a few lines without even knowing how Movim does it.
But you actually want to see how it's done on the wire, isn't it?
Let's take a small example with john@movim.eu publishing an article on her blog. 😛
<iq id='pub1'
to='john@movim.eu'
type='set'>
<pubsub xmlns='http://jabber.org/protocol/pubsub'>
<publish node='urn:xmpp:microblog:0'>
<item id='1cb57d9c-1c46-11dd-838c-001143d5d5db'>
<entry xmlns='http://www.w3.org/2005/Atom'>
<title type='text'>Trying out Movim ✨</title>
<id>1cb57d9c-1c46-11dd-838c-001143d5d5db</id>
<published>2025-05-08T18:30:02Z</published>
<updated>2025-05-08T18:30:02Z</updated>
</entry>
</item>
</publish>
</pubsub>
</iq>
This is what Movim is actually sending when John publishes an article on her blog. An XMPP library will also be able to do it; if you're motivated, you can also write it by hand (but you don't need to; that's why you have libraries and clients for that! 💪).
More in detail, we can see the actual article in the <entry/> element; it contains a title, an identifier and some dates of publication and update. The example is super simplified but know that you can put way more information (like attached files, tags...). And as you can see it is an actual standard Atom 1.0 element so you can easily take articles from your WordPress blog or any other website that can generate an Atom or RSS feed and publish them on your XMPP blog, natively!
We actually publish this entry in a specific item having a unique ID on the node urn:xmpp:microblog:0(that is the standard identifier for all the blogs on the XMPP network) and we send it directly to the john@movim.eu account.
If John wants to update her article, he just has to publish it again on the same item. If he wants to publish a new one, he publishes another <entry/> in a new item having a new identifier on the same node, super simple!
And how can I subscribe to a blog and be notified?
Movim used to have an implicit subscription system; this means that when John and Yoko were added mutually as contacts they were automatically receiving each other's blog notifications. This wasn't really understood by our users and was quite hard to understand; it also had some limitations.
In Movim 0.32 the subscription will be explicit, with a simple Follow button. This means that you no longer need to be friends mutually to follow each other, and that you can just follow anyone (that has a public blog, you can also restrict your blog to your contacts only if you want) on the network.
Now let's imagine that Yoko wants to follow John's blog. Using her own XMPP client she simply has to send a subscribe message to the node where John is publishing his articles.
<iq type='set'
from='yoko@jabber.fr/movim'
to='john@movim.eu'
id='sub1'>
<pubsub xmlns='http://jabber.org/protocol/pubsub'>
<subscribe node='urn:xmpp:microblog:0'/>
</pubsub>
</iq>
And that's it 😎! See how simple XMPP is?
In the future when John publishes a new article his own XMPP server will check all the persons that are subscribed to the node and directly push a message with the fresh article in it (there are some optimizations involved there to reduce the load, but let's keep things simple ☺️). Here Movim is just an interface to write the article and publish it; the XMPP server is actually taking care of handling the article and delivering it to everyone, and they can do it massively with very little resource.
What's next?
Movim 0.32 is bringing a totally new approach to how you blog on the XMPP network. In the upcoming months we are planning to integrate more features around that new Follow button, like being able to list your subscribers, get some general statistics on the amount of followers that an account has, or get notified instantly when someone subscribes to your blog.
We found that some of the XMPP servers we're using were missing some of the standardized features at the moment, some tickets were opened (see ejabberd#4484, prosody#1972, ejabberd#4483, ejabberd#4481 and prosody#1973 and once those features are integrated, Movim will follow up. 😌
In the XMPP community we think that taking time to discuss and work together to standardize all the concepts we want to integrate in the protocol is the best way to make it the best, most modular, reliable and scalable protocol out there to handle all our social interactions online. Don't hesitate to join us (and invite your friends 😸) if you have questions or you want to develop crazy ideas on the protocol.
That's all, folks! 🎉













