Apply to a Fill Color property (shape layer or text). Define your color palette in the expression, then each layer picks a random color from it.
1. Select the Fill Color property
2. Alt/Option-click the stopwatch
3. Paste this expression
4. Customise the palette array with your brand colors
Create visual variety across duplicated layers without manually assigning colors. Each layer automatically picks a different color from your palette based on its index.
Perfect for data visualisations, abstract backgrounds, confetti, and any time you need controlled randomness within a defined color scheme.
- 1.Set speed to 0 for consistent colors per layer (based on index)
- 2.Higher speed values = colors change over time
- 3.Customise the palette array with your brand colors in [R, G, B, A] format (0ā1 range)
- 4.The seedRandom function ensures consistent results ā same index always gets same color