Display a message of the day in Trac


This plugin allows the system-administrator to display a message of the day (MOTD) on every Trac page. Once the user acknowledges the message, it is no longer shown. It is similar to the NewsFlashMacro, with the difference that every page is affected instead of only the ones where the macro is embedded.

For a sysadmin it was always hard to inform every Trac user about upcoming system updates, maintenance periods, hardware changes or similar. With this plugin it is now possible to display such message(s) on every Trac page, even when having many projects, by simply editing one text file.

Bugs/Feature Requests

Existing bugs and feature requests for MotdPlugin are here.

If you have any issues, create a new ticket.


1 / 1


0 / 1


Download the zipped source from here.


Check out MotdPlugin from here using Subversion, or browse the source with Trac.


General instructions on installing Trac plugins can be found on the TracPlugins page.


MotdPlugin can be configured with the following options in your trac.ini file:

message_file = /data/messag_of_the_day.ini
message_dir = /data/motd.d
date_format = <planned>
frame_width = <motd-frame width in pixel>
frame_height = <motd-frame height in pixel>


  • default: /data/motd.ini
  • location of the file containing the messages to display


  • default: /data/motd.d
  • directory containing HTML-files with messages to display

date_format (planned)

  • default: %Y-%m-%d %H:%M
  • allows configuration of the date-format for parameter valid_until. format is given in python 'datetime' format.


  • default: 400px
  • sets the width of the MOTD-frame in pixel (range: 400-900)


  • default: 300px
  • sets the height of the MOTD-frame in pixel (range: 300-800)

motd.ini file

MotdPlugin uses an ini-style file for configuring the messages that should be displayed:

title = <message header>
message = <message text (in one line!)>
priority = <message priority, for future use>
valid_until = <expiration date for message>
repeat = n-i

The section name (MsgName) has to be unique within the message file. Format of the expiration date is (currently) "yyyy-mm-dd HH:MM", next version will have a configurable format.

repeat specifies how often (n) and in which interval (i) the message should be displayed. n must be a positive integer and i must be in the range of: m for minutely, h for hourly, d for daily and w for weekly.


title = System Maintenance
message = Trac services will be unavailable next Friday from 4pm to 6pm!
valid_until = 2011-04-24 18:00

title = New version of xxx has been installed
valid_until = 2011-05-13 23:59
repeat = 3-d

The first example should be self explanatory. In the second example there is the message parameter missing! In that case MotdPlugin searches for a file named Message2.html in the directory specified by message_dir in trac.ini and displays the complete content of this file. This message will be shown 3 times, interval is daily. If the expiration date is before the repeat period finishes, the message is no longer shown.

Recent Changes

13979 by rjollos on 2014-06-17 09:08:11
Replaced tabs with spaces and fixed indentation.
10027 by ChristianM on 2011-04-05 15:17:30
fix bug #8648 (remove with-statement to be compatible with older
python versions)
additional some cosmetic fixes
9964 by ChristianM on 2011-03-16 19:37:44
  • restructured htdocs (moved *.js and *.css in seperate dirs)
  • add admin interface
  • add "repeat"


Author: ChristianM
Maintainer: Christian Masopust

Last modified 7 years ago Last modified on Nov 18, 2015, 11:00:36 AM