Skip to content

Support 301 redirection for account migration #8465

Description

Mastodon now has UX for account migration - hooray!
However, it doesn't actually redirect the account and followers . I can still post in the old instance, and my followers still see it, they still have to follow me in my new instance separately.

Now deep down at the HTTP level, there is an answer for this - the 301 redirect, which says 'go to this new URL instead, and remember that for next time you look (as opposed to the 302 redirect, which says 'go to this new URL for now, but check the original one again next time).

Websub (the OStatus way of sending posts to followers) explicitly recommends this - this was clarified with mastodon in mind and has a test.

ActivityPub (the other way of doing this that Mastodon implements) doesn't specify migration directly, but does normatively reference HTTP so 301 should apply there too.

This has 2 components - serving 301s correctly, which presumably would use the moved_to_account_id field to get the updated values when information is requested, and responding to 301s correctly, which should just involve updating the various URLs and domains in the account record.

Lack of this is widely noted as a problem with federation, as people stumble onto an instance initially, and then are unsure how to move fully to another one e.g.

Migrating does not retain your followers. Anybody who follows you will be left following your old dead account
lifehacker


Forked from the old migration issue as that has got into the weeds of compromised instances. This is for the relatively simple 'I have moved from instance a to instance b' case that we have UI for.
set it up in settings
and it shows up on profile

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions