Random Dessert Recipe Generator
Generate random dessert recipes with filters for category, difficulty, and dietary needs. Complete with ingredients, instructions, and serving adjustments.
About
Deciding what to bake is often harder than baking itself. Decision fatigue leads to repeated recipes or abandoned plans. This generator contains a curated database of 50 dessert recipes spanning 8 categories from cakes to frozen treats. Each recipe includes precise ingredient quantities, step-by-step instructions, and timing data. Filters narrow the pool by difficulty (1 - 3 scale), category, and dietary restrictions before random selection. Serving sizes scale linearly: adjustedAmount = baseAmount × desiredServingsbaseServings. Note: scaling works reliably for most ingredients but baking chemistry (leavening agents, eggs) may require manual adjustment beyond ±50% of the original yield.
Formulas
Ingredient quantities adjust proportionally to the desired serving count. The core scaling formula applied to each ingredient:
Where Ascaled = adjusted ingredient amount, Abase = original recipe amount, Sdesired = target number of servings, and Sbase = original recipe servings.
Random selection uses rejection sampling over the filtered recipe set. Given a filtered pool of n recipes, each recipe has selection probability:
The generator uses crypto.getRandomValues() for uniform distribution rather than Math.random(), which relies on a PRNG with potential bias in modular arithmetic. The unbiased index is computed as:
Where randomUint32 is sourced from a 32-bit unsigned integer via the Web Crypto API.
Reference Data
| Category | Example Desserts | Typical Prep Time | Difficulty Range | Common Allergens |
|---|---|---|---|---|
| Cakes | Lemon Drizzle, Chocolate Fudge, Carrot Cake | 20 - 45 min | Easy - Hard | Gluten, Eggs, Dairy |
| Cookies | Chocolate Chip, Snickerdoodle, Macarons | 15 - 30 min | Easy - Medium | Gluten, Eggs, Nuts |
| Pies & Tarts | Apple Pie, Lemon Tart, Pecan Pie | 25 - 50 min | Medium - Hard | Gluten, Dairy, Nuts |
| Puddings | Crème Brûlée, Rice Pudding, Panna Cotta | 10 - 30 min | Easy - Medium | Dairy, Eggs |
| Frozen | Gelato, Sorbet, Ice Cream Sandwiches | 15 - 40 min | Easy - Medium | Dairy, Nuts |
| Pastries | Croissants, Éclairs, Baklava | 30 - 90 min | Medium - Hard | Gluten, Dairy, Nuts |
| No-Bake | Cheesecake, Truffles, Energy Balls | 10 - 25 min | Easy | Dairy, Nuts |
| Fruit Desserts | Pavlova, Fruit Tart, Compote | 15 - 35 min | Easy - Medium | Eggs, Dairy |
| Scaling Reference | ||||
| Flour | Scales linearly | 1× ratio | ||
| Sugar | Scales linearly | 1× ratio | ||
| Eggs | Round to nearest whole | Round(n × ratio) | ||
| Baking Powder | Reduce by 10% when doubling | 0.9× ratio (if ≥2×) | ||
| Butter | Scales linearly | 1× ratio | ||
| Salt | Scale conservatively | 0.8× ratio (if ≥2×) | ||
| Vanilla Extract | Diminishing returns at scale | 0.75× ratio (if ≥3×) | ||
| Gelatin | Scales linearly | 1× ratio | ||
| Cream | Scales linearly | 1× ratio | ||
| Chocolate | Scales linearly | 1× ratio | ||