ActivityPub is a
protocol and
open standard
An open standard is a standard that is openly accessible and usable by anyone. It is also a common prerequisite that open standards use an open license that provides for extensibility. Typically, anybody can participate in their development due to ...
for
decentralized
Decentralization or decentralisation is the process by which the activities of an organization, particularly those related to planning and decision-making, are distributed or delegated away from a central, authoritative location or group and gi ...
social networking
A social network is a social structure consisting of a set of social actors (such as individuals or organizations), networks of Dyad (sociology), dyadic ties, and other Social relation, social interactions between actors. The social network per ...
. It provides a
client-to-server (C2S)
API
An application programming interface (API) is a connection between computers or between computer programs. It is a type of software interface, offering a service to other pieces of software. A document or standard that describes how to build ...
for creating and modifying content, as well as a
federated server-to-server (S2S) protocol for delivering notifications and content to other servers. ActivityPub has become the main standard used in the
fediverse
The Fediverse (commonly shortened to fedi) is a collection of social networking services that can communicate with each other (formally known as Federation (information technology), federation) using a common protocol. Users of different websites ...
, a popular network used for social networking that consists of software such as
Mastodon
A mastodon, from Ancient Greek μαστός (''mastós''), meaning "breast", and ὀδούς (''odoús'') "tooth", is a member of the genus ''Mammut'' (German for 'mammoth'), which was endemic to North America and lived from the late Miocene to ...
,
Pixelfed and
PeerTube.
ActivityPub is considered to be an update to the ActivityPump protocol used in
pump.io, and the official W3C repository for ActivityPub is identified as a fork of ActivityPump. The creation of a new standard for
decentralized social networking was prompted by the complexity of
OStatus, the most commonly used protocol at the time. OStatus was built using a multitude of technologies (such as
Atom
Atoms are the basic particles of the chemical elements. An atom consists of a atomic nucleus, nucleus of protons and generally neutrons, surrounded by an electromagnetically bound swarm of electrons. The chemical elements are distinguished fr ...
,
Salmon
Salmon (; : salmon) are any of several list of commercially important fish species, commercially important species of euryhaline ray-finned fish from the genera ''Salmo'' and ''Oncorhynchus'' of the family (biology), family Salmonidae, native ...
,
WebSub and
WebFinger
WebFinger is a Communications protocol, protocol specified by the Internet Engineering Task Force IETF in RFC:7033, RFC 7033 that allows for discovery of information about people and things identified by a URI. Information about a person migh ...
), a product of the infrastructure used in
GNU social (the originator and largest user of the OStatus protocol), which made it difficult to implement the protocol into new software. OStatus was also only designed to work with
microblogging
Microblogging is a form of blogging using short posts without titles known as microposts or status updates. Microblogs "allow users to exchange small elements of content such as short sentences, individual images, or video links", which may be the ...
services, with little flexibility to the types of data that it could hold.
The standard was first published by the
World Wide Web Consortium
The World Wide Web Consortium (W3C) is the main international standards organization for the World Wide Web. Founded in 1994 by Tim Berners-Lee, the consortium is made up of member organizations that maintain full-time staff working together in ...
(W3C) as a W3C Recommendation in January 2018 by the Social Web Working Group (SocialWG), a
working group
A working group is a group of experts working together to achieve specified goals. Such groups are domain-specific and focus on discussion or activity around a specific subject area. The term can sometimes refer to an interdisciplinary collab ...
chartered to build the protocols and vocabularies needed to create a standard for social functionality. Shortly after, further development was moved to the Social Web Community Group (SocialCG), the successor to the SocialWG.
Design
ActivityPub uses the
ActivityStreams 2.0 format for building its content, which itself uses
JSON-LD
JSON-LD (JavaScript Object Notation for Linked Data) is a method of encoding linked data using JSON. One goal for JSON-LD was to require as little effort as possible from developers to transform their existing JSON to JSON-LD. JSON-LD allows data ...
. The three main data types used in ActivityPub are Objects, Activities and Actors. Objects are the most common data type, and can be images, videos, or more abstract items such as locations or events. Activities are actions that create and modify objects, for example a activity creates an object. Actors are representative of an individual, a group, an application or a service, and are the owners of objects.
Every actor type contains an inbox and outbox stream, which sends and receives activities for a user. In order to publish data (for example liking an article), a user creates an activity that declares that they liked an Article object and publishes it to their outbox, where it is then delivered by the ActivityPub server via a
POST request to the inboxes listed in the activity's , , and fields. The receiving servers then account for the newly received activity and update the article by adding the like action to it.
Example data
An example actor object that represents a
user account
A user is a person who uses a computer or network service.
A user often has a user account and is identified to the system by a username (or user name).
Some software products provide services to other systems and have no direct end use ...
:
An example activity that likes an article object:
An example article object:
Project status
The SocialCG previously organized a yearly free conference called ActivityPub Conf about the future of ActivityPub. Triages are held regularly to review issues pertaining to the ActivityPub and ActivityStreams 2.0 specifications as part of the SocialCG.
In 2023, Germany's
Sovereign Tech Fund
The Sovereign Tech Agency is a subsidiary of the German Federal Agency for Disruptive Innovation, funded by the Federal Ministry for Economic Affairs and Climate Action, aimed at providing financial support to open-source software. The initial fun ...
donated €152,000 to socialweb.coop with the goal of building a new suite for testing various ActivityPub implementations and their compliance with the specification.
Adoption
The initial wave of adoption for ActivityPub (circa 2016-2018) came from software that was already using OStatus as their federation protocol, such as
Mastodon
A mastodon, from Ancient Greek μαστός (''mastós''), meaning "breast", and ὀδούς (''odoús'') "tooth", is a member of the genus ''Mammut'' (German for 'mammoth'), which was endemic to North America and lived from the late Miocene to ...
,
GNU social and
Pleroma
Pleroma (, literally "fullness") generally refers to the totality of divine powers. It is used in Christian theological contexts, as well as in Gnosticism. The term also appears in the Epistle to the Colossians, which is traditionally attributed ...
. Following the
acquisition of Twitter by Elon Musk
Businessman and U.S. political figure Elon Musk initiated an Mergers and acquisitions, acquisition of the American social media company Twitter, Inc. on April 14, 2022, and concluded it on October 27, 2022. Musk had begun buying shares of the ...
in 2022, many groups of users that were critical of the acquisition migrated to Mastodon, bringing new attention to the ActivityPub protocol with it. Various major social media platforms and corporations have since pledged to implement ActivityPub support, including
Tumblr
Tumblr (pronounced "tumbler") is a microblogging and Social networking service, social networking website founded by David Karp in 2007 and is owned by American company Automattic. The service allows users to post multimedia and other content ...
,
Flipboard and
Meta Platforms
Meta Platforms, Inc. is an American multinational technology company headquartered in Menlo Park, California. Meta owns and operates several prominent social media platforms and communication services, including Facebook, Instagram, Threads ...
'
Threads.
Criticism
Accidental denial-of-service attacks
Poorly
optimized ActivityPub implementations can cause unintentional
distributed denial-of-service (DDOS) attacks on other websites and servers, due to the decentralized nature of the network. An example would be
Mastodon
A mastodon, from Ancient Greek μαστός (''mastós''), meaning "breast", and ὀδούς (''odoús'') "tooth", is a member of the genus ''Mammut'' (German for 'mammoth'), which was endemic to North America and lived from the late Miocene to ...
's implementation of
OpenGraph link previews, wherein every instance that receives a post that contains a link with OpenGraph metadata will download the associated data, such as a
thumbnail
Thumbnails are reduced-size versions of pictures or videos, used to help in recognizing and organizing them, serving the same role for images as a normal text index does for words. In the age of digital images, visual search engines and image-o ...
, in a very short timeframe, which can slow down or crash servers as a result of the sudden burst of requests.
Account migration
ActivityPub has been criticized for not natively supporting moving accounts from one server to another, forcing implementations to build their own solutions. While there has been work on building a standardized system for migrating accounts using the Move activity via the Fediverse Enhancement Proposal organization, the current proposal only allows for basic follower migration, with all other data remaining linked to the original account.
Missing content and data
ActivityPub implementations have been criticized for missing replies and parts of reply threads from remote posts, and presenting outdated statistics (e.g. likes and reposts) about remote posts. However, this isn't a problem with the ActivityPub protocol itself, but with implementations not
refreshing their content for updated data when needed.
Software using ActivityPub
Future implementations
*
GitLab
GitLab is a software forge primarily developed by GitLab Inc. It is available as a community edition and a commercial edition.
History
GitLab was created in 2011 by Ukrainian programmer Dmitriy Zaporozhets as a side project written in Rub ...
, a Git
forge
A forge is a type of hearth used for heating metals, or the workplace (smithy) where such a hearth is located. The forge is used by the smith to heat a piece of metal to a temperature at which it becomes easier to shape by forging, or to the ...
and development platform
*
Forgejo, a Git forge and development platform
*
Tumblr
Tumblr (pronounced "tumbler") is a microblogging and Social networking service, social networking website founded by David Karp in 2007 and is owned by American company Automattic. The service allows users to post multimedia and other content ...
, a microblogging platform
See also
*
AT Protocol
The AT Protocol (Authenticated Transfer Protocol, pronounced " @ protocol" and commonly shortened to ATProto) is a protocol and open standard for distributed social networking services. It is under development by Bluesky Social PBC, a public ...
*
Comparison of microblogging and similar services
*
*
Fediverse
The Fediverse (commonly shortened to fedi) is a collection of social networking services that can communicate with each other (formally known as Federation (information technology), federation) using a common protocol. Users of different websites ...
*
Micropub
*
OStatus
References
External links
*
ActivityPub specification
{{W3C standards
2018 introductions
Distributed computing
Microblogging software
Social software
Fediverse
Web applications
Communications protocols
Software that federates via ActivityPub