Works on this device
Random Loot Table Generator
Type or paste your own loot tables, with weights or with dice ranges, and roll on them. An entry can roll an amount such as {2d6} or roll on another table. The page shows the exact chance of every entry, and a seed that gives the same rolls again. It holds no tables of any published game: the tables are yours.
Your loot tables
Check these values
This is off unless you turn it on. Saved entries stay in this browser only. Untick the box to delete them.
Your tables are read and rolled in this browser. They are not sent to a server.
The loot will show here
Choose Roll to roll on your tables.
Result
How it was worked out
How to use the loot table generator
- Type your tables in the box, or open a text file. The page starts with three made-up tables that you can change.
- Start each table with its name in brackets:
[Gems]for a table with weights, or[Treasure d20]for a table you roll with a die. - Under the name, write one entry on each line. In a table with weights, write the weight, a colon and the entry:
3: A wooden button. In a table with a die, write the range, a colon and the entry:1-8: copper coins. - Choose how many times to roll, and choose Roll. The loot is listed first, then every single roll with the dice that came up.
- Choose Chance of each entry to see how likely each entry is, or Make a die table from weights to turn a list with weights into ranges of a real die.
What you can write in an entry
{2d6}rolls two six-sided dice and puts the total in the text.{1d4+1}adds 1.{3d6x10}multiplies the total by 10. So{2d6} copper coinscan give "7 copper coins".[Gems]rolls once on your table named Gems and puts its result in the text.[Gems x3]rolls on it three times.- A table can roll on another table, which can roll on a third, up to 10 levels. Tables that roll on each other in a loop are refused.
- A line that holds only a name in brackets starts a new table. For an entry that is only a roll on another table, write its weight or range in front:
1: [Gems]. - Dice tables:
[Name d20],[Name d100](alsod%, and00means 100), or two or more dice such as[Name 2d6]. The ranges must cover every result of the dice exactly once. - You can also start a table with
# Name d20in place of the brackets. Lines before the first name make a table with weights named Loot.
How the chances are worked out
In a table with weights, the chance of an entry is its weight ÷ the sum of the weights. With the weights 3, 2, 2 and 1 the sum is 8, so the first entry has a chance of 3/8 = 37.5%.
In a table with a die, the chance is the number of ways the die can land in the range ÷ all the ways it can land. On a d20 the range 1-8 has 8 of 20 ways: 40%. With two or more dice the middle totals come more often: on 2d6 a total of 7 has 6 of 36 ways, a total of 2 only 1.
For an entry of a table that is reached through a link, the page shows the expected number of times it comes in one roll of the starting table: the chance of the link × the number of rolls it asks for × the chance of the entry, through every level. The chance to get an entry at least once in n rolls is 1 − (1 − p)ⁿ.
All these numbers are worked out exactly with whole numbers and fractions. They are shown as fractions and as percents.
The seed: the same rolls again
The rolls come from a seed. The seed starts a number generator named xoshiro128** (started through a step named SplitMix64). For one seed it always gives the same row of random bytes, and each die is taken from these bytes without favouring any face.
Leave the seed empty for new rolls: your browser then draws a fresh seed with its secure random generator. Type a seed again, with the same tables and settings, to get the same loot. A seed is not a secret, so do not use it for prize draws.
Worked example
With the starting tables, the table Treasure is rolled with a d20. A roll of 17 or 18 means a roll on Trinkets: a chance of 2/20 = 10%. A roll of 19 means two rolls on Trinkets: 5%. So Trinkets is rolled 0.1 × 1 + 0.05 × 2 = 0.2 times in one roll of Treasure, on average.
In Trinkets the wooden button has the weight 3 of 8. So it comes 0.2 × 3/8 = 3/40 = 0.075 times in one roll of Treasure.
Make a die table from the weights 5, 3, 2 and 1 for a d20: the sum is 11. 5/11 of 20 faces is 9.09, so the first entry gets 9 faces; the others get 5, 4 and 2 faces after the largest-remainder rule (5.45, 3.64 and 1.82 rounded so that the faces add up to 20). The ranges are 1-9, 10-14, 15-18 and 19-20.
Limits you should know
- The tables are yours. The page has no tables, monsters or items of any published game, and it does not know the rules of your game.
- Up to 30 tables of up to 500 entries each, and up to 10 levels of tables. One run can make up to 10,000 table rolls.
- Each roll is new: an entry can come more than once. Rolls without repeats are not offered.
- An amount can be 0 or less when you take a number away, such as {1d4-3}. The page does not stop that.
- The page does not send your tables to a server. It keeps them in this browser only when you tick Save my entries on this device.