Published:

Table of Contents

Shameless Advert

Join our open fedi relay! relay.disobey.net

Related Documentation

Change the post and bio max character counts in Mastodon

Introduction

I run the disobey.net and nautical.social Mastodon instances. I self-host these as standalone servers built from source, not Docker. This configuration change I've only performed since upgrading to Mastodon v4.3.1, so I cannot guarantee that it will work on Mastodon v4.2.x or earlier.

All file editing below is from my Mastodon root directory, "~/live".

Mastodon changes

You will only need to edit this one file:

vim app/models/account.rb

Find the "DEFAULT_FIELDS_SIZE" line. Change the "4" at the end of that line to however many fields you'd like:

DEFAULT_FIELDS_SIZE = 4

I changed it to 9 fields:

edit number of profile fields screenshot

Save and quit, if you're using vim:

:wq

As the mastodon user:

RAILS_ENV=production bundle exec rails assets:precompile

As root user:

systemctl restart mastodon-web mastodon-sidekiq mastodon-streaming

After the restart, you'll see this in https://domain.tld/settings/profile:

profile fields screenshot

Thanks for making the fediverse better!

Notes

Ivory (mobile app) does not currently recognize any more fields than 4, but any desktop browser user will still see them. So it's my opinion that after the 4th field, less important links/text should go there. It does not break Ivory, it's just an inconvenience. I hope Ivory fixes it!