Mastodon Migration Filters: How to Re-Apply at New Instance
🔍 WiseChecker

Mastodon Migration Filters: How to Re-Apply at New Instance

When you move your Mastodon account to a new instance, your follower migration is handled automatically, but the custom filters you set up to block or mute specific words, phrases, and users do not travel with you. These filters are stored locally on your old instance and are not part of the standard account migration process. This article explains why filters are left behind and provides the exact steps to re-apply them on your new instance so you can restore your content moderation environment.

Key Takeaways: Reapplying Mastodon Filters After Instance Migration

  • Preferences > Filters > Import: Use the built-in import tool to upload a CSV file containing all your old filters.
  • Export filters before leaving the old instance: You must export your filters from the old account before starting the migration process.
  • CSV format for filter import: Each row must include keyword or phrase, whole word flag, and expiration date to import correctly.

ADVERTISEMENT

Why Mastodon Filters Do Not Migrate With Your Account

Mastodon account migration transfers followers, follows, lists, and blocks to the new instance. Filters are excluded from this process because they are considered instance-specific settings tied to the local database of the server you are leaving. The migration feature was designed to move social connections, not personal content moderation rules. This means that after you complete the move, your new instance starts with zero filters. You must recreate them manually or use the import/export feature if you prepared ahead of time.

What the Migration Actually Transfers

When you initiate a move from your old account to a new one, Mastodon transfers the following data automatically:

  • All followers (they receive a follow request to the new account)
  • All accounts you follow
  • All lists you created
  • All blocks (muted and blocked users)
  • Your profile display name, bio, and avatar

Filters are not in this list. They remain on the old instance even after the account is deleted or redirected. If you do not export them before starting the migration, you lose them permanently.

Steps to Re-Apply Filters on Your New Mastodon Instance

You have two options to restore your filters: export from the old instance and import to the new instance, or recreate them manually. The export-import method is faster and recommended if you still have access to your old account.

Method 1: Export Filters from the Old Instance Before Migration

  1. Log into your old Mastodon account
    Open your old instance in a browser and sign in with your credentials.
  2. Navigate to Preferences > Import and Export > Export
    Click the menu icon in the top right, select Preferences, then click Import and Export in the left sidebar. Under the Export tab, locate the section labeled Filters.
  3. Download the filters CSV file
    Click the Export button next to Filters. Your browser downloads a CSV file named filters.csv. Save this file to a secure location on your computer.
  4. Proceed with your account migration
    Complete the migration process from your old account to the new instance. After the move is finished, log into your new instance.

Method 2: Import Filters to the New Instance

  1. Log into your new Mastodon account
    Open your new instance in a browser and sign in.
  2. Go to Preferences > Import and Export > Import
    Click the menu icon, select Preferences, then click Import and Export. Switch to the Import tab.
  3. Choose the filters CSV file
    Click the Choose File button and select the filters.csv file you exported from your old instance.
  4. Set the import type to Filters
    From the dropdown menu labeled What do you want to import, select Filters.
  5. Select the merge mode
    Choose Merge to add the imported filters to any existing filters on the new instance. Choose Overwrite to replace all existing filters with the imported ones. For a fresh instance with no filters, either option works.
  6. Click Upload
    Mastodon processes the CSV file and applies the filters. A confirmation message appears when the import is complete.

Method 3: Manually Recreate Filters on the New Instance

If you did not export your filters before leaving the old instance, you must recreate them manually. This is time-consuming but necessary.

  1. Open Preferences > Filters
    On your new instance, click the menu icon, select Preferences, then click Filters in the left sidebar.
  2. Click Add new filter
    A form opens where you can define the filter keyword or phrase.
  3. Enter the keyword or phrase
    Type the exact word or phrase you want to filter. Check the box for Whole word if you want to match only standalone occurrences.
  4. Set the filter context
    Choose where the filter applies: Home and lists, Notifications, Public timeline, or Conversations. Select all that apply.
  5. Set an expiration date (optional)
    If the filter is temporary, enter an expiration date. Leave blank for permanent filters.
  6. Click Save
    The filter is added immediately. Repeat for each filter you need to recreate.

ADVERTISEMENT

Common Issues When Reapplying Filters After Migration

CSV Import Shows Error or No Filters Appear

The CSV file exported from your old instance must follow a specific format. Open the CSV in a text editor to verify the header row. The required columns are: keyword, whole_word, expires_at, context, filter_action. If any column is missing or the file is corrupted, the import fails. Download a fresh export from the old instance if possible. If the old account is no longer accessible, you must recreate the filters manually.

Filters Applied but Not Working on New Instance

After import, filters may not take effect immediately if the new instance runs a different Mastodon version. Check that your new instance is updated to at least Mastodon version 4.0. Older versions do not support the filter_action column. If the instance is outdated, upgrade it or contact the admin. You can also delete the imported filters and recreate them using the manual method, which always works regardless of version.

Exported Filters Include Old Instance-Specific Data

The CSV file may contain filters that reference users or servers from your old instance. These filters still work because they match text, not instance IDs. However, if you had filters that targeted specific users by account handle, those handles remain valid only if the users are still active on the same instances. Update any stale handles after the import by editing the filter in Preferences > Filters.

Item Export and Import Manual Recreation
Time required 5 minutes 30 minutes to several hours depending on filter count
Requires old account access Yes No
Risk of data loss Low if CSV is saved correctly None
Compatibility with old instance version CSV format must match current Mastodon version Works with any version

Now you can restore your Mastodon content moderation environment after moving to a new instance. Before starting your next migration, export your filters first to save time. For advanced management, consider using the Mastodon API to script bulk filter imports if you have many filters to reapply.

ADVERTISEMENT