// the whole pipeline, per postcode
seed = FNV-1a(postcode)              // fold the code into one 32-bit number
rand = mulberry32(seed)              // a fast PRNG, seeded by that number
sett = mirror(bands(rand, palette[region]))
tartan = warp(sett) + weft(sett, 50% opacity) + twill

Here comes the weave stepper

Watch a postcode go through every stage of the loom, then run it with your own.

1 · BINARY

The postcode's characters as raw bits.

2 · HALF SETT

The bits deal out grounds and guard lines.

3 · MIRRORED

Reflected about the last stripe, as real setts are.

4 · WOVEN

Warp and weft crossed, twill on top.

From postcode to numbers

We validate the postcode and look up one thing about it, its region, which chooses the palette. Everything else comes from the postcode string itself. Each character is turned into its byte value, giving a run of binary, and that run is folded into a single 32-bit number with the FNV-1a hash. The number seeds a small, fast pseudo-random generator called mulberry32. The word pseudo is the point: the output looks scattered but is completely fixed by the postcode, so the same code always produces the same threads and we never store anything.

Building the sett

A tartan is defined by its sett, the repeating run of coloured stripes. We build half a sett by stepping through the seeded generator, alternating wide ground bands (the deep greens, navies and claret) with thin accent and guard lines (the golds and creams), giving each a colour and a thread count taken from the numbers. Then we mirror that half around its last band. The mirror is what makes it read as a real tartan rather than a random barcode, because genuine setts are symmetric and look the same forwards and backwards.

Weaving it, not striping it

This is the part that turns stripes into cloth. The same sett is drawn twice: once as vertical threads (the warp) at full strength, and once as horizontal threads (the weft) laid over the top at half opacity. Where two threads of the same colour cross you get that colour solid; where two different colours cross, the eye sees the average of the pair, a softer mixed shade. That blend at every crossing is how real woven tartan behaves, and it is why the checks have their muted, layered look rather than the flat bands of a deck chair. A faint diagonal hatch on top, set to the traditional twill angle, adds the final hint of weave.

Colour by region, pattern by postcode

The UK's regions map to eight palette families, so a Highland postcode is dealt greens, gold and heather while a London one leans to claret and black. Postcodes near each other therefore rhyme by eye, which is the opposite of schemes that deliberately scatter neighbours. The rest, the number of bands, their widths and their order, all comes from the postcode's own bits.

One each, across 1.8 million

Because the design is a function of the postcode, two different codes almost never collide, and seeding from the full code means even near-identical postcodes diverge. There is no store of tartans behind this. Each one is worked out on the spot as a small piece of maths, and the same input always gives the same cloth: deterministic, offline, and entirely ours, with no AI involved, no external service and no licence.

Common questions

How is the tartan made from my postcode?
Your postcode is converted to binary, the same 0s and 1s a computer sees. That binary is folded into a single number which drives a deterministic generator. Runs of the output choose each stripe's colour and width, and the pattern is mirrored into a proper symmetric sett. The region sets the colour family, so a Highland postcode is woven in greens and golds while a London one leans to claret.

Will the same postcode always give the same tartan?
Yes. The design is fully deterministic: the same postcode produces exactly the same tartan every time, forever. Nothing is random and nothing is stored.

Is this a real, registered tartan?
No. It is a generated design for fun and personal use, not a tartan registered with the Scottish Register of Tartans, and it has no clan or official status.

Is AI used to generate the tartans?
No. The tartans are generated by a small, fixed algorithm: a hash, a pseudo-random number generator and a set of weaving rules. No AI or image models are involved, which is why the results are perfectly repeatable.

Can I download and use my postcode tartan?
Yes. You can download it as a crisp SVG, a high-resolution PNG or a phone wallpaper, free for personal use such as prints, backgrounds and social posts.