Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time


Migration script for SMF2 forum to Flarum, partially based on the phpbb_to_flarum script by robrotheram, VIRUXE, Reflic

Where to download it

You find the script on GitHub


The Script exports and migrates your SMF2 (possibly SMF1.x) forum to Flarum. It supports:

  • a DB to DB migration,
  • a DB to ASCII SQL file export.

These two functionalities can be performed together or as alternatives.

Flarum is still in beta testing, therefore only some of the typical web forum features are available, and what is now working can break anytime (including this script, tailored for flarum ver. 0.1.0-beta.5). At this moment smf2_to_flarum only supports migration of:

  • Users and their avatars (no passwords are exported. Migrated users will have to ask for a new one).
  • Boards and sub boards (Categories are intentionally ignored, and boards deeper than 2nd level are added in Flarum as extra Tags)
  • Topics and messages (with some bbcode to flarum-markdown translation)
  • Attachments (partial, only images)


  • 2016-08-28: Version 0.3 Alpha
    • Added preliminary image attachments export
    • General bugfix.
  • 2016-08-27: Version 0.2 Alpha
  • 2016-08-26: Version 0.1 Alpha
    • First commit (for flarum ver. 0.1.0-beta.5)

Known issues / Future features


  • Install a vanilla Flarum, with empty database.
  • Copy smf2_to_flarum.php (or smf2_to_flarum_alternative.php) and smf2_to_flarum_settings.php in your SMF forum root.
  • Customise smf2_to_flarum_settings.php script settings with the correct username/password for your SMF2 and (optionally) Flarum DB, and enable/disable the export settings (all enabled by default).
  • Run the script as

Alternative version

The alternative version of the script (smf2_to_flarum_alternative.php) needs the following tools to be installed on the same server where SMF2 is installed:


The script saves users' avatars in a directory named "avatars". From there the avatars shall be manually copied into flarum "assets/avatars" directory.


Attachment management is not part of flarum core. In order to have attachments functionality in flarum the "Image Upload" extension has to be installed and enabled (see

The migration script exports only image attachments, since no other attachment type is supported at the moment. Files are extracted from single or multiple directory attachment system of SMF/SMF2 then stored in a directory named "images".

From this directory the attachments shall be manually copied in "assets/images" directory of your flarum installation.

Help us

Feel free to contribute to this project!


SMF2 to Flarum DB importer







No releases published


No packages published