1. Use a game in class
- Available games are listed at teaching.beer-lab.org (the student view) and, for instructors, at teaching-admin.beer-lab.org: admin panels, rooms, configurations, duration, and the results each game displays.
- Email the lab with the game, course, number of students, and date; we give you access to the game's admin panel (
https://<game>.beer-lab.org/login). You can then run as many sessions as you have groups. - Students do not need an account or any installation: they open teaching.beer-lab.org on their phones, find the game specified by their instructor, and choose their language.
2. Run a session step by step
- Before class: log in to the admin panel (
https://<game>.beer-lab.org/login, usernameadmin), create a session from Demo, and work through it in two or three tabs to become familiar with the screens and report. - In class: Rooms → room for your language → Create session. Choose the configuration (for example, one round or ten rounds) and the number of participants, with a few extra places. Language is per session: a session created in the Spanish room only admits students who enter through the Español button, and vice versa. For a mixed group, pick one language for the whole session or create one session per language.
- Project or share teaching.beer-lab.org and specify the game name and language. Each student finds the game in the directory, selects the button for their language, and waits on the welcome screen until the group is complete.
- Track progress in Monitor. If someone falls behind, you can see which page they are on.
- At the end, open the session's Report tab (in games that include one) to project and discuss aggregate results; use Data → Export to download the CSV if you want to work with it in class.
- Select Rooms → Close session to prepare the room for the next group.
- Ask students not to refresh or close their tabs during the game; if they do, they can return through the directory, choosing the same game and language in the same browser, to resume where they left off.
- An odd number of participants in a paired game leaves one person waiting: join on your own phone to complete the pair, or create the session with one fewer participant.
- Data stay on the lab server and are backed up nightly; no personal data are collected unless the game states otherwise.
3. Propose a new game
Any instructor can propose an oTree game for the collection. Requirements for the teaching track:
- A participant interface that works on phones, with a BEER Lab welcome page, instructions, and comprehension checks.
- Results to project: ideally an aggregate report (Report tab), or at least exportable data that can be plotted in class.
- Rooms by language or variant, so sessions can be created without editing settings.
- Avoid Spanish
(a)/(o)word endings; do not collect students' personal data.
Start from the lab template — publicly available at github.com/ecastrom/otree_template, with sample pages and a design guide — or from the published Dictator Game, an example of a complete teaching game (three variants, two languages, instructor report). Email the lab to request its code.
Structure and technical requirements
my_game/
├── settings.py ← at the root; ROOMS and SESSION_CONFIGS go here
├── requirements.txt ← otree==6.x.y and psycopg2-binary
├── my_app/ ← __init__.py, templates/, admin_report.html (optional)
├── _static/ _templates/ ← logo and room welcome page
- Use
ADMIN_PASSWORD = environ.get('OTREE_ADMIN_PASSWORD')andSECRET_KEY = environ.get('OTREE_SECRET_KEY', ...); do not defineDATABASE_URL,DEBUG, orAUTH_LEVEL. - Before submitting, run
otree test <config>for each configuration and complete a full walkthrough on a phone. - Subdomain name: the game's name, lowercase, 3–20 characters (
dictator,ultimatum,bienes-publicos).
4. Submit your project
Zip the folder as <name>-v1.zip (excluding .venv, db.sqlite3, __pycache__, and data) and send it to [email protected] with the subject [oTree] <name> v1 — teaching. Include:
settings.py and requirements.txt must be at the root of the zip (or inside one single folder); the server accepts up to 40 MB. No Procfile, runtime.txt or Dockerfile is needed: the server uses its own recipe (Python 3.11 and oTree from your requirements.txt).
| Information | Example |
|---|---|
| Game title (in Spanish and, if applicable, English) and a one-line directory description | Juego del dictador · Dictator Game — one round or ten rounds… |
| Keywords (relevant course topics) and JEL codes for directory search and filters | altruism, social preferences · C91, D64 |
| Preferred subdomain | dictator |
| Rooms and session configurations, with the language of each | room dictador (ES): 3 configurations; room dictator (EN): 3 |
| Participants per group, estimated duration, and report contents | pairs · 15–40 min · mean, histogram… |
| Authorship and contact | Name and phone number |
5. What happens next
- The lab reviews and deploys the game at
https://<name>.beer-lab.org, adds it to teaching.beer-lab.org and the instructor directory, and notifies you by email. Panel access is provided separately. - If the build fails, you receive the error and a suggested fix; submit
<name>-v2.zip. - Updates: send a new zip with a version number. If you changed the models (fields), the database is reset; download any data you want to keep beforehand.
- Removal: request it by email; the lab keeps a backup and removes the site.
- When the lab publishes a new game (yours or anyone else's), every beer-lab.org address is unreachable for about 15 seconds (a Cloudflare "Error 1033" page appears; reloading fixes it and participants keep their progress). No games are published during scheduled classes: tell the lab your dates.
For technical details and the server Dockerfile, see GUIDE_FOR_RESEARCHERS.md, published with the lab's oTree template.
6. License and reuse
Unless otherwise noted, the text of this site and the BEER Lab teaching guides are licensed under CC BY 4.0: you may use, copy, translate and adapt them for your classes, at any institution, as long as you credit the source. Suggested credit: “Guide title, author(s). BEER Lab, Tecnológico de Monterrey. CC BY 4.0.”
Games proposed by other people keep the terms set by their authors. Working papers belong to their authors. The game code and the Tec and BEER Lab logos are not covered by the license.