Skip to main content

Homeserver for the Matrix decentralised comms protocol

Project description

Synapse is an open-source Matrix homeserver written and maintained by the Matrix.org Foundation. We began rapid development in 2014, reaching v1.0.0 in 2019. Development on Synapse and the Matrix protocol itself continues in earnest today.

Briefly, Matrix is an open standard for communications on the internet, supporting federation, encryption and VoIP. Matrix.org has more to say about the goals of the Matrix project, and the formal specification describes the technical details.

Installing and configuration

The Synapse documentation describes how to install Synapse. We recommend using Docker images or Debian packages from Matrix.org.

Synapse has a variety of config options which can be used to customise its behaviour after installation. There are additional details on how to configure Synapse for federation here.

Using a reverse proxy with Synapse

It is recommended to put a reverse proxy such as nginx, Apache, Caddy, HAProxy or relayd in front of Synapse. One advantage of doing so is that it means that you can expose the default https port (443) to Matrix clients without needing to run Synapse with root privileges. For information on configuring one, see the reverse proxy docs.

Upgrading an existing Synapse

The instructions for upgrading Synapse are in the upgrade notes. Please check these instructions as upgrading may require extra steps for some versions of Synapse.

Platform dependencies

Synapse uses a number of platform dependencies such as Python and PostgreSQL, and aims to follow supported upstream versions. See the deprecation policy for more details.

Security note

Matrix serves raw, user-supplied data in some APIs – specifically the content repository endpoints.

Whilst we make a reasonable effort to mitigate against XSS attacks (for instance, by using CSP), a Matrix homeserver should not be hosted on a domain hosting other web applications. This especially applies to sharing the domain with Matrix web clients and other sensitive applications like webmail. See https://developer.github.com/changes/2014-04-25-user-content-security for more information.

Ideally, the homeserver should not simply be on a different subdomain, but on a completely different registered domain (also known as top-level site or eTLD+1). This is because some attacks are still possible as long as the two applications share the same registered domain.

To illustrate this with an example, if your Element Web or other sensitive web application is hosted on A.example1.com, you should ideally host Synapse on example2.com. Some amount of protection is offered by hosting on B.example1.com instead, so this is also acceptable in some scenarios. However, you should not host your Synapse on A.example1.com.

Note that all of the above refers exclusively to the domain used in Synapse’s public_baseurl setting. In particular, it has no bearing on the domain mentioned in MXIDs hosted on that server.

Following this advice ensures that even if an XSS is found in Synapse, the impact to other applications will be minimal.

Testing a new installation

The easiest way to try out your new Synapse installation is by connecting to it from a web client.

Unless you are running a test instance of Synapse on your local machine, in general, you will need to enable TLS support before you can successfully connect from a client: see TLS certificates.

An easy way to get started is to login or register via Element at https://app.element.io/#/login or https://app.element.io/#/register respectively. You will need to change the server you are logging into from matrix.org and instead specify a Homeserver URL of https://<server_name>:8448 (or just https://<server_name> if you are using a reverse proxy). If you prefer to use another client, refer to our client breakdown.

If all goes well you should at least be able to log in, create a room, and start sending messages.

Registering a new user from a client

By default, registration of new users via Matrix clients is disabled. To enable it:

  1. In the registration config section set enable_registration: true in homeserver.yaml.

  2. Then either:

    1. set up a CAPTCHA, or

    2. set enable_registration_without_verification: true in homeserver.yaml.

We strongly recommend using a CAPTCHA, particularly if your homeserver is exposed to the public internet. Without it, anyone can freely register accounts on your homeserver. This can be exploited by attackers to create spambots targetting the rest of the Matrix federation.

Your new user name will be formed partly from the server_name, and partly from a localpart you specify when you create the account. Your name will take the form of:

@localpart:my.domain.name

(pronounced “at localpart on my dot domain dot name”).

As when logging in, you will need to specify a “Custom server”. Specify your desired localpart in the ‘User name’ box.

Troubleshooting and support

The Admin FAQ includes tips on dealing with some common problems. For more details, see Synapse’s wider documentation.

For additional support installing or managing Synapse, please ask in the community support room #synapse:matrix.org (from a matrix.org account if necessary). We do not use GitHub issues for support requests, only for bug reports and feature requests.

Identity Servers

Identity servers have the job of mapping email addresses and other 3rd Party IDs (3PIDs) to Matrix user IDs, as well as verifying the ownership of 3PIDs before creating that mapping.

They are not where accounts or credentials are stored - these live on home servers. Identity Servers are just for mapping 3rd party IDs to matrix IDs.

This process is very security-sensitive, as there is obvious risk of spam if it is too easy to sign up for Matrix accounts or harvest 3PID data. In the longer term, we hope to create a decentralised system to manage it (matrix-doc #712), but in the meantime, the role of managing trusted identity in the Matrix ecosystem is farmed out to a cluster of known trusted ecosystem partners, who run ‘Matrix Identity Servers’ such as Sydent, whose role is purely to authenticate and track 3PID logins and publish end-user public keys.

You can host your own copy of Sydent, but this will prevent you reaching other users in the Matrix ecosystem via their email address, and prevent them finding you. We therefore recommend that you use one of the centralised identity servers at https://matrix.org or https://vector.im for now.

To reiterate: the Identity server will only be used if you choose to associate an email address with your account, or send an invite to another user via their email address.

Development

We welcome contributions to Synapse from the community! The best place to get started is our guide for contributors. This is part of our larger documentation, which includes

information for Synapse developers as well as Synapse administrators. Developers might be particularly interested in:

Alongside all that, join our developer community on Matrix: #synapse-dev:matrix.org, featuring real humans!

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

matrix_synapse-1.81.0.tar.gz (3.2 MB view details)

Uploaded Source

Built Distributions

matrix_synapse-1.81.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.2 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

matrix_synapse-1.81.0-pp39-pypy39_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl (4.2 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

matrix_synapse-1.81.0-pp39-pypy39_pp73-macosx_11_0_x86_64.whl (3.2 MB view details)

Uploaded PyPy macOS 11.0+ x86-64

matrix_synapse-1.81.0-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.2 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

matrix_synapse-1.81.0-pp38-pypy38_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl (4.2 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

matrix_synapse-1.81.0-pp38-pypy38_pp73-macosx_11_0_x86_64.whl (3.2 MB view details)

Uploaded PyPy macOS 11.0+ x86-64

matrix_synapse-1.81.0-pp37-pypy37_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.2 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

matrix_synapse-1.81.0-pp37-pypy37_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl (4.2 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

matrix_synapse-1.81.0-pp37-pypy37_pp73-macosx_11_0_x86_64.whl (3.2 MB view details)

Uploaded PyPy macOS 11.0+ x86-64

matrix_synapse-1.81.0-cp37-abi3-musllinux_1_1_x86_64.whl (4.3 MB view details)

Uploaded CPython 3.7+ musllinux: musl 1.1+ x86-64

matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.2 MB view details)

Uploaded CPython 3.7+ manylinux: glibc 2.17+ x86-64

matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl (4.2 MB view details)

Uploaded CPython 3.7+ manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (4.2 MB view details)

Uploaded CPython 3.7+ manylinux: glibc 2.17+ ARM64

matrix_synapse-1.81.0-cp37-abi3-macosx_10_16_x86_64.whl (3.2 MB view details)

Uploaded CPython 3.7+ macOS 10.16+ x86-64

File details

Details for the file matrix_synapse-1.81.0.tar.gz.

File metadata

  • Download URL: matrix_synapse-1.81.0.tar.gz
  • Upload date:
  • Size: 3.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.6

File hashes

Hashes for matrix_synapse-1.81.0.tar.gz
Algorithm Hash digest
SHA256 28074fe1f3cabcaa97004a4c625416d48875ca22b8729b515cbe006dc43696cf
MD5 3d243a212efc7c15f5386ea03f4056b3
BLAKE2b-256 8af219220b79392969f80a468052f73871c81c70b04f719598d1499930bd753a

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 738f962b734d8ad36fd00c7a56c28fae2e3a79f9c7023f1965c5c4c32db2356d
MD5 6cd5a0500ab71293d273e724e52d9eac
BLAKE2b-256 2e1cecaba39fdac1659981e1aad946ecf19a9cc9a7e23e4b64733067b9b4f2e8

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp39-pypy39_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp39-pypy39_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 af581282810b86a382d89f31be3e1aa5ac698d0a4e3d46e47c4bc84d0e002ed9
MD5 7f7cf906369cbcd0bca30526e27202aa
BLAKE2b-256 c57be7cac47778124776386b6923d4116974977fd3ab3dc43a3a49ff443f09e1

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp39-pypy39_pp73-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp39-pypy39_pp73-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 2450b5770c33cdf27610a7f121f7d544985c274823ae7c2fd3169ab18d375abc
MD5 d8b5e39e09c47b18b4d978a4f963698f
BLAKE2b-256 56cc5451d8b1f0229505796098f1dae0d39beb7462c96d2b1fd03597356da12a

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 714f1b2c9a63e1ebd721ec4b24f3ef2370c71796d4566e0e5a36a132e18ae8bc
MD5 19ebd15443f9090a8b69062eaeecb464
BLAKE2b-256 e517eb8bc2f0d07ac9140a1ef985a0f2dff0d414efe9972e40981f362c02158d

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp38-pypy38_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp38-pypy38_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 df125736b8f6ef5992c2481bfd20ba584ea3b54af778d10be518968c498ad295
MD5 db4ce5114492d08c1ac42f0c5aeb70d6
BLAKE2b-256 8682ad62db6f686091706d326e186c80c6a50eba2c7304f00d3cc9e122d4a413

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp38-pypy38_pp73-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp38-pypy38_pp73-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 30a3e5c0d9dfc54a8c9af9d33b9f070623840b54d7d28401dc751436d2103299
MD5 af84457f7116b12756e5201f5b8efae1
BLAKE2b-256 210d94ccb670da074452f4a266c14f13c864373b39fb342e935b689d27bc2076

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp37-pypy37_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp37-pypy37_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 94b2d3ecdd9c34880f303c7db728aea8d3284070dbbdca35183a3dd0546cf262
MD5 45bc7a37ca8eb24b0338e43ee7e4676a
BLAKE2b-256 c557e3bcaa0ab8c33328839140cfecb694a1b0f5f1db106a06d1a6b73b3d624e

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp37-pypy37_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp37-pypy37_pp73-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 0bc61b5107678052ed48bb117f9c41d847405832bb01a22bb80b27c7a8be2d80
MD5 65b48d48969af1024dc00f6abfdfaf93
BLAKE2b-256 cece50dc40a63816631ebf8b780aca23f82c6ab99ee9136b469033d212b2cea6

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-pp37-pypy37_pp73-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-pp37-pypy37_pp73-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 e4db608c549cfe3c5f0acff35064d795378d01f57c181d9fda514317a164e6a2
MD5 2b3e27d6738250724f28e71b3ec1e06a
BLAKE2b-256 57052cf89b612a6ba690c429767712816a5623d4a177c4924266bb2c911f20f3

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-cp37-abi3-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-cp37-abi3-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 843fb1a3e3129800e5de7fc3ecfa18c5e99a79c29e46d7febb61c128cb0b8f4d
MD5 f6312738a31f8753628a563786db2c07
BLAKE2b-256 3999061dcb7afa7e2e327e85fdd6f625c1f79333051c5478378560e83c5e8c50

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 ebba83e47925976a4f922fcf7f680b2c73aae1ac1678cc51a5e5c8f58f7d1c00
MD5 2e31add3d31e4b1b0684dc4f2e60d2d1
BLAKE2b-256 6287406cd37eba6ae6b9b23ea0ba98d8c042ddb28c70011bbf4a18da9d59141d

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_i686.manylinux_2_5_i686.manylinux1_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 fb5b9ca94671fc565f3a4436630cfc70c594882c5d37bcac4ed7c68ea59919b0
MD5 ff156ac639735545fffbdfe816260c38
BLAKE2b-256 375813a086d09f713c9cea68d1f66f09a21f2eeb2923b18a11cba5c2a4ccbb59

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 a5ef44ac9ac9bdfdb8d2c44aced333dad89f9f7b056a9f0015a624a8d78c9243
MD5 eb2ae6f79fcbd9cc77b8ca4c7b908e46
BLAKE2b-256 d666fa15991c0b28e5868a7dac2fc72f24e827b69313b47a68fde9fe0027744c

See more details on using hashes here.

Provenance

File details

Details for the file matrix_synapse-1.81.0-cp37-abi3-macosx_10_16_x86_64.whl.

File metadata

File hashes

Hashes for matrix_synapse-1.81.0-cp37-abi3-macosx_10_16_x86_64.whl
Algorithm Hash digest
SHA256 767e2bee75a1bea9dee1f29b896aba46a61b467d96e107710cef033a221f6e6c
MD5 2e62c25fea070280727d3d11c6444d81
BLAKE2b-256 2dbfe0e333a0068effe6425b5e917abae61bb5ed746972ec5488e99e69506c0e

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page