{"id":47,"date":"2025-11-18T19:11:47","date_gmt":"2025-11-18T19:11:47","guid":{"rendered":"https:\/\/godseyonline.net\/?p=47"},"modified":"2025-11-18T19:21:35","modified_gmt":"2025-11-18T19:21:35","slug":"mastodon-character-limit-and-poll-options-increase-for-4-5-1-on-yunohost","status":"publish","type":"post","link":"https:\/\/godseyonline.net\/index.php\/2025\/11\/18\/mastodon-character-limit-and-poll-options-increase-for-4-5-1-on-yunohost\/","title":{"rendered":"Mastodon Character Limit  and Poll Options Increase for 4.5.1 on Yunohost"},"content":{"rendered":"\n<h3 class=\"wp-block-heading\">Increasing or Modifying the Character Limit<\/h3>\n\n\n\n<p>At\u00a0our church Mastodon instance, the character limit is set to 5000 (up from the 500 originally allowed by Mastodon). <\/p>\n\n\n\n<p>You will need to use the root account to modify these files. You can do this by SSH by issuing the following command in the terminal:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo su -<\/code><\/pre>\n\n\n\n<p>To customize this limit, you need to modify two files:<\/p>\n\n\n\n<p><code><strong>live\/app\/javascript\/mastodon\/features\/compose\/containers\/compose_form_container.js<\/strong><\/code>\u00a0&#8211; find the line that contains:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>maxChars: state.getIn(&#91;'server', 'server', 'configuration', 'statuses', 'max_characters'], 500),<\/code><\/code><\/pre>\n\n\n\n<p>and change&nbsp;<code>500<\/code>&nbsp;to your desired value.<\/p>\n\n\n\n<p>Next, you need to modify another file:\u00a0<code><strong>live\/app\/validators\/status_length_validator.rb<\/strong><\/code>\u00a0&#8211; find the line that contains:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>MAX_CHARS = 500<\/code><\/code><\/pre>\n\n\n\n<p>and change it accordingly.<\/p>\n\n\n\n<p>To run the next command you will need to first issue this command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>sudo yunohost app shell mastodon<\/code><\/code><\/pre>\n\n\n\n<p>Once done, run the following command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>RAILS_ENV=production bundle exec rails assets:precompile<\/code><\/code><\/pre>\n\n\n\n<p>Exit the shell by typing:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>exit<\/code><\/pre>\n\n\n\n<p>and restart the Mastodon services to apply the changes:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>systemctl restart mastodon-web.service mastodon-sidekiq.service<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Increasing or Modifying the Number of Poll Options<\/h3>\n\n\n\n<p>Edit the file\u00a0<code><strong>live\/app\/validators\/poll_options_validator.rb<\/strong><\/code>\u00a0and modify the line:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>MAX_OPTIONS = 4<\/code><\/code><\/pre>\n\n\n\n<p>to the value you want. There are also other customizable options in this file.<\/p>\n\n\n\n<p>Again, once done, you will need to first issue this command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>sudo yunohost app shell mastodon<\/code><\/code><\/pre>\n\n\n\n<p>Once done, run the following command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>RAILS_ENV=production bundle exec rails assets:precompile<\/code><\/code><\/pre>\n\n\n\n<p>Exit the shell by typing:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>exit<\/code><\/pre>\n\n\n\n<p>and restart the Mastodon services to apply the changes:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>systemctl restart mastodon-web.service mastodon-sidekiq.service<\/code><\/pre>\n\n\n\n<p>These modifications might be overridden by subsequent Mastodon updates, so be sure to check after every update that they are still valid.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Increasing or Modifying the Character Limit At\u00a0our church Mastodon instance, the character limit is set to 5000 (up from the 500 originally allowed by Mastodon). You will need to use the root account to modify these files. You can do this by SSH by issuing the following command in the terminal: To customize this limit, &#8230; <a title=\"Mastodon Character Limit  and Poll Options Increase for 4.5.1 on Yunohost\" class=\"read-more\" href=\"https:\/\/godseyonline.net\/index.php\/2025\/11\/18\/mastodon-character-limit-and-poll-options-increase-for-4-5-1-on-yunohost\/\" aria-label=\"Read more about Mastodon Character Limit  and Poll Options Increase for 4.5.1 on Yunohost\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[19,10,20],"class_list":["post-47","post","type-post","status-publish","format-standard","hentry","category-computers","tag-character-limits","tag-mastodon","tag-poll-options"],"_links":{"self":[{"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/posts\/47","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/comments?post=47"}],"version-history":[{"count":1,"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/posts\/47\/revisions"}],"predecessor-version":[{"id":48,"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/posts\/47\/revisions\/48"}],"wp:attachment":[{"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/media?parent=47"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/categories?post=47"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/godseyonline.net\/index.php\/wp-json\/wp\/v2\/tags?post=47"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}